From 7636aa79abfb8d7698f36d37cbcc0b5746add2cf Mon Sep 17 00:00:00 2001 From: Takeshi Shibagaki Date: Mon, 12 Jan 2004 14:18:55 +0000 Subject: Fix a suspend/resume issue. My Compaq N400c works fine. --- sys/dev/usb/uhci.c | 3 +++ sys/dev/usb/uhci_pci.c | 2 ++ 2 files changed, 5 insertions(+) (limited to 'sys/dev/usb') diff --git a/sys/dev/usb/uhci.c b/sys/dev/usb/uhci.c index 15162f08184a1..d969272aeda0b 100644 --- a/sys/dev/usb/uhci.c +++ b/sys/dev/usb/uhci.c @@ -724,6 +724,9 @@ uhci_power(int why, void *v) #endif sc->sc_bus.use_polling++; sc->sc_suspend = why; + UWRITE2(sc, UHCI_INTR, 0); /* disable interrupts */ + uhci_globalreset(sc); /* reset the controller */ + uhci_reset(sc); if (cmd & UHCI_CMD_RS) uhci_run(sc, 0); /* in case BIOS has started it */ diff --git a/sys/dev/usb/uhci_pci.c b/sys/dev/usb/uhci_pci.c index 48996f613282a..b2632012ff1fb 100644 --- a/sys/dev/usb/uhci_pci.c +++ b/sys/dev/usb/uhci_pci.c @@ -166,6 +166,8 @@ uhci_pci_resume(device_t self) { uhci_softc_t *sc = device_get_softc(self); + pci_write_config(self, PCI_LEGSUP, PCI_LEGSUP_USBPIRQDEN, 2); + uhci_power(PWR_RESUME, sc); bus_generic_resume(self); -- cgit v1.3