diff options
author | n_hibma <n_hibma@FreeBSD.org> | 2000-02-04 10:18:37 +0000 |
---|---|---|
committer | n_hibma <n_hibma@FreeBSD.org> | 2000-02-04 10:18:37 +0000 |
commit | ffc4c1858f3d68a6cfee5b63ce40cb00620dc359 (patch) | |
tree | 580316d72f02b7c295f1372dae63ec2e945eb6dc /sys/pci/uhci_pci.c | |
parent | d241516a4a0b31dc54638c4ebcd178495a26cf77 (diff) | |
download | FreeBSD-src-ffc4c1858f3d68a6cfee5b63ce40cb00620dc359.zip FreeBSD-src-ffc4c1858f3d68a6cfee5b63ce40cb00620dc359.tar.gz |
Commit missing bits, forgotten when committing support for suspend/resume
for USB.
Call uhci_power when suspending and resuming.
Approved by: The One.
Diffstat (limited to 'sys/pci/uhci_pci.c')
-rw-r--r-- | sys/pci/uhci_pci.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/sys/pci/uhci_pci.c b/sys/pci/uhci_pci.c index d635b07..0fbade0 100644 --- a/sys/pci/uhci_pci.c +++ b/sys/pci/uhci_pci.c @@ -93,8 +93,13 @@ static const char *uhci_device_generic = "UHCI (generic) USB controller"; static int uhci_pci_suspend(device_t self) { + uhci_softc_t *sc = device_get_softc(self); + int err; - bus_generic_suspend(self); + err = bus_generic_suspend(self); + if (err) + return err; + uhci_power(PWR_SUSPEND, sc); return 0; } @@ -102,11 +107,9 @@ uhci_pci_suspend(device_t self) static int uhci_pci_resume(device_t self) { -#if 0 uhci_softc_t *sc = device_get_softc(self); - uhci_reset(sc); -#endif + uhci_power(PWR_RESUME, sc); bus_generic_resume(self); return 0; |