diff options
author | David Gwynne <dlg@cvs.openbsd.org> | 2005-02-12 05:23:36 +0000 |
---|---|---|
committer | David Gwynne <dlg@cvs.openbsd.org> | 2005-02-12 05:23:36 +0000 |
commit | f4b607d4b7ec51ae9136ff77f72f7d713c7d9d4b (patch) | |
tree | 75c462709509f42c64b04c6a59b47b5928a7b880 /sys | |
parent | 262f059b11178aa582cc718bd2314bdf06084199 (diff) |
remove the need for duplicate knowledge between autoconfig and the driver.
ok drahn@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/arm/xscale/pxa2x0_ohci.c | 16 | ||||
-rw-r--r-- | sys/arch/zaurus/conf/GENERIC | 4 |
2 files changed, 7 insertions, 13 deletions
diff --git a/sys/arch/arm/xscale/pxa2x0_ohci.c b/sys/arch/arm/xscale/pxa2x0_ohci.c index 4934e78400f..e1641eca4dd 100644 --- a/sys/arch/arm/xscale/pxa2x0_ohci.c +++ b/sys/arch/arm/xscale/pxa2x0_ohci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pxa2x0_ohci.c,v 1.6 2005/01/26 21:29:36 dlg Exp $ */ +/* $OpenBSD: pxa2x0_ohci.c,v 1.7 2005/02/12 05:23:35 dlg Exp $ */ /* * Copyright (c) 2005 David Gwynne <dlg@openbsd.org> @@ -56,15 +56,9 @@ struct cfattach pxaohci_ca = { int pxaohci_match(struct device *parent, void *match, void *aux) { - struct pxaip_attach_args *pxa = aux; - - if (((cputype & ~CPU_ID_XSCALE_COREREV_MASK) != CPU_ID_PXA27X) || - (pxa->pxa_addr != PXA2X0_USBHC_BASE) || - (pxa->pxa_intr != PXA2X0_INT_USBH1)) + if ((cputype & ~CPU_ID_XSCALE_COREREV_MASK) != CPU_ID_PXA27X) return (0); - pxa->pxa_size = PXA2X0_USBHC_SIZE; - return (1); } @@ -78,17 +72,17 @@ pxaohci_attach(struct device *parent, struct device *self, void *aux) sc->sc.iot = pxa->pxa_iot; sc->sc.sc_bus.dmatag = pxa->pxa_dmat; - sc->sc_intr = pxa->pxa_intr; + sc->sc_intr = PXA2X0_INT_USBH1; sc->sc_ih = NULL; sc->sc.sc_size = 0; /* Map I/O space */ - if (bus_space_map(sc->sc.iot, pxa->pxa_addr, pxa->pxa_size, 0, + if (bus_space_map(sc->sc.iot, PXA2X0_USBHC_BASE, PXA2X0_USBHC_SIZE, 0, &sc->sc.ioh)) { printf(": cannot map mem space\n"); return; } - sc->sc.sc_size = pxa->pxa_size; + sc->sc.sc_size = PXA2X0_USBHC_SIZE; /* XXX copied from ohci_pci.c. needed? */ bus_space_barrier(sc->sc.iot, sc->sc.ioh, 0, sc->sc.sc_size, diff --git a/sys/arch/zaurus/conf/GENERIC b/sys/arch/zaurus/conf/GENERIC index cab5b8b7465..e9a1d7094c3 100644 --- a/sys/arch/zaurus/conf/GENERIC +++ b/sys/arch/zaurus/conf/GENERIC @@ -1,4 +1,4 @@ -# $OpenBSD: GENERIC,v 1.26 2005/02/01 15:41:24 drahn Exp $ +# $OpenBSD: GENERIC,v 1.27 2005/02/12 05:23:35 dlg Exp $ # # GENERIC machine description file # @@ -63,7 +63,7 @@ pxagpio0 at pxaip? # GPIO scoop0 at pxaip? scoop1 at pxaip? saost0 at pxaip? addr 0x40a00000 size 0x20 -ohci0 at pxaip? addr 0x4c000000 size 0x70 intr 3 +ohci0 at pxaip? usb* at ohci? # touch screen |