From 2255c5b248866c67307275d5d279bcf3fceb54bb Mon Sep 17 00:00:00 2001 From: n_hibma Date: Wed, 15 Mar 2000 22:12:47 +0000 Subject: Do not use the powerhooks at all, instead of abusing and empty #define. --- sys/dev/usb/uhci.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'sys/dev/usb/uhci.c') diff --git a/sys/dev/usb/uhci.c b/sys/dev/usb/uhci.c index 4cd3a3d..79ce9c2 100644 --- a/sys/dev/usb/uhci.c +++ b/sys/dev/usb/uhci.c @@ -95,7 +95,7 @@ struct cfdriver uhci_cd = { #ifdef UHCI_DEBUG #define DPRINTF(x) if (uhcidebug) printf x #define DPRINTFN(n,x) if (uhcidebug>(n)) printf x -int uhcidebug = 0; +int uhcidebug = 1; #else #define DPRINTF(x) #define DPRINTFN(n,x) @@ -427,8 +427,8 @@ uhci_init(sc) sc->sc_bus.pipe_size = sizeof(struct uhci_pipe); sc->sc_suspend = PWR_RESUME; - sc->sc_powerhook = powerhook_establish(uhci_power, sc); #if defined(__NetBSD__) || defined(__OpenBSD__) + sc->sc_powerhook = powerhook_establish(uhci_power, sc); sc->sc_shutdownhook = shutdownhook_establish(uhci_shutdown, sc); #endif DPRINTFN(1,("uhci_init: enabling\n")); @@ -476,8 +476,10 @@ uhci_detach(sc, flags) if (rv != 0) return (rv); +#if defined(__NetBSD__) || defined(__OpenBSD__) powerhook_disestablish(sc->sc_powerhook); shutdownhook_disestablish(sc->sc_shutdownhook); +#endif /* Free all xfers associated with this HC. */ for (;;) { -- cgit v1.1