diff options
Diffstat (limited to 'sys/dev/ar/if_ar_pci.c')
-rw-r--r-- | sys/dev/ar/if_ar_pci.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/sys/dev/ar/if_ar_pci.c b/sys/dev/ar/if_ar_pci.c index 314e859..07a9edf 100644 --- a/sys/dev/ar/if_ar_pci.c +++ b/sys/dev/ar/if_ar_pci.c @@ -107,7 +107,6 @@ ar_pci_attach(device_t device) { int error; u_int i, tmp; - u_char *inten; struct ar_hardc *hc; hc = (struct ar_hardc *)device_get_softc(device); @@ -125,13 +124,11 @@ ar_pci_attach(device_t device) if(error) goto errexit; - hc->plx_mem = rman_get_virtual(hc->res_plx_memory); hc->mem_start = rman_get_virtual(hc->res_memory); hc->cunit = device_get_unit(device); hc->sca[0] = (sca_regs *)(hc->mem_start + AR_PCI_SCA_1_OFFSET); hc->sca[1] = (sca_regs *)(hc->mem_start + AR_PCI_SCA_2_OFFSET); - hc->iobase = 0; hc->orbase = (u_char *)(hc->mem_start + AR_PCI_ORBASE_OFFSET); tmp = hc->orbase[AR_BMI * 4]; @@ -159,8 +156,8 @@ ar_pci_attach(device_t device) ar_attach(device); /* Magic to enable the card to generate interrupts. */ - inten = (u_char *)hc->plx_mem; - inten[0x69] = 0x09; + bus_space_write_1(rman_get_bustag(hc->res_plx_memory), + rman_get_bushandle(hc->res_plx_memory), 0x69, 0x09); return (0); |