Enclose .hcidebug in '#ifdef N.HCI'
This commit is contained in:
parent
461b249325
commit
157ddd9539
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: usb.c,v 1.11 1999/01/08 11:58:25 augustss Exp $ */
|
||||
/* $NetBSD: usb.c,v 1.12 1999/01/10 19:13:16 augustss Exp $ */
|
||||
/* $FreeBSD$ */
|
||||
|
||||
/*
|
||||
@ -68,6 +68,8 @@ MALLOC_DEFINE(M_USB, "USB", "USB");
|
||||
MALLOC_DEFINE(M_USBDEV, "USBdev", "USB device");
|
||||
|
||||
#include "usb_if.h"
|
||||
#include "uhci.h"
|
||||
#include "ohci.h"
|
||||
#endif /* defined(__FreeBSD__) */
|
||||
|
||||
#include <dev/usb/usbdi.h>
|
||||
@ -78,7 +80,13 @@ MALLOC_DEFINE(M_USBDEV, "USBdev", "USB device");
|
||||
#define DPRINTF(x) if (usbdebug) logprintf x
|
||||
#define DPRINTFN(n,x) if (usbdebug>(n)) logprintf x
|
||||
int usbdebug = 1;
|
||||
extern int uhcidebug, ohcidebug;
|
||||
|
||||
#if NUHCI > 0
|
||||
extern int uhcidebug;
|
||||
#endif
|
||||
#if NOHCI > 0
|
||||
extern int ohcidebug;
|
||||
#endif
|
||||
#else
|
||||
#define DPRINTF(x)
|
||||
#define DPRINTFN(n,x)
|
||||
@ -223,7 +231,13 @@ usbioctl(dev, cmd, data, flag, p)
|
||||
switch (cmd) {
|
||||
#ifdef USB_DEBUG
|
||||
case USB_SETDEBUG:
|
||||
usbdebug = uhcidebug = ohcidebug = *(int *)data;
|
||||
usbdebug = *(int *)data;
|
||||
#if NUHCI > 0
|
||||
uhcidebug = *(int *)data;
|
||||
#endif
|
||||
#if NOHCI > 0
|
||||
ohcidebug = *(int *)data;
|
||||
#endif
|
||||
break;
|
||||
#endif
|
||||
case USB_DISCOVER:
|
||||
@ -349,7 +363,7 @@ usb_bus_count()
|
||||
}
|
||||
#endif
|
||||
|
||||
#if defined(__NetBSD__)
|
||||
#if 0
|
||||
usbd_status
|
||||
usb_get_bus_handle(n, h)
|
||||
int n;
|
||||
@ -403,9 +417,9 @@ usb_needs_explore(bus)
|
||||
int
|
||||
usb_detach(device_t self)
|
||||
{
|
||||
DPRINTF(("%s: disconnected\n", USBDEVNAME(self)));
|
||||
DPRINTF(("%s: unload, prevented\n", USBDEVNAME(self)));
|
||||
|
||||
return (1);
|
||||
return (EINVAL);
|
||||
}
|
||||
|
||||
DRIVER_MODULE(usb, uhci, usb_driver, usb_devclass, 0, 0);
|
||||
|
Loading…
Reference in New Issue
Block a user