summaryrefslogtreecommitdiffstats
path: root/sys/dev/usb/uhci.c
diff options
context:
space:
mode:
authorjoe <joe@FreeBSD.org>2002-04-07 09:57:23 +0000
committerjoe <joe@FreeBSD.org>2002-04-07 09:57:23 +0000
commitac39184235635c3cc1bc98cffa0f3e9a26eb1db0 (patch)
tree32e78e38ea426ed5ebbd749968e5a04efe4f15df /sys/dev/usb/uhci.c
parent017a3a7612bfda2c2c61f574fa70be24a7a0d07f (diff)
downloadFreeBSD-src-ac39184235635c3cc1bc98cffa0f3e9a26eb1db0.zip
FreeBSD-src-ac39184235635c3cc1bc98cffa0f3e9a26eb1db0.tar.gz
MFNetBSD:
revision 1.142 date: 2001/10/25 02:08:13; author: augustss; lines: +14 -16 Change reset sequence to get status change bits set right on startup.
Diffstat (limited to 'sys/dev/usb/uhci.c')
-rw-r--r--sys/dev/usb/uhci.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/sys/dev/usb/uhci.c b/sys/dev/usb/uhci.c
index 978a764..d65a2b8 100644
--- a/sys/dev/usb/uhci.c
+++ b/sys/dev/usb/uhci.c
@@ -1,4 +1,4 @@
-/* $NetBSD: uhci.c,v 1.141 2001/10/24 21:04:04 augustss Exp $ */
+/* $NetBSD: uhci.c,v 1.142 2001/10/25 02:08:13 augustss Exp $ */
/* $FreeBSD$ */
/*
@@ -157,7 +157,8 @@ struct uhci_pipe {
} u;
};
-Static void uhci_busreset(uhci_softc_t *);
+Static void uhci_globalreset(uhci_softc_t *);
+Static void uhci_reset(uhci_softc_t *);
#if 0
Static void uhci_reset(uhci_softc_t *);
#endif
@@ -370,7 +371,7 @@ uhci_find_prev_qh(uhci_soft_qh_t *pqh, uhci_soft_qh_t *sqh)
}
void
-uhci_busreset(uhci_softc_t *sc)
+uhci_globalreset(uhci_softc_t *sc)
{
UHCICMD(sc, UHCI_CMD_GRESET); /* global reset */
usb_delay_ms(&sc->sc_bus, USB_BUS_RESET_DELAY); /* wait a little */
@@ -394,10 +395,10 @@ uhci_init(uhci_softc_t *sc)
uhci_dumpregs(sc);
#endif
- uhci_run(sc, 0); /* stop the controller */
UWRITE2(sc, UHCI_INTR, 0); /* disable interrupts */
- uhci_busreset(sc);
+ uhci_globalreset(sc); /* reset the controller */
+ uhci_reset(sc);
/* Allocate and initialize real frame array. */
err = usb_allocmem(&sc->sc_bus,
@@ -1521,7 +1522,6 @@ uhci_poll(struct usbd_bus *bus)
uhci_intr1(sc);
}
-#if 0
void
uhci_reset(uhci_softc_t *sc)
{
@@ -1536,7 +1536,6 @@ uhci_reset(uhci_softc_t *sc)
printf("%s: controller did not reset\n",
USBDEVNAME(sc->sc_bus.bdev));
}
-#endif
usbd_status
uhci_run(uhci_softc_t *sc, int run)
OpenPOWER on IntegriCloud