diff options
author | Marc Balmer <mbalmer@cvs.openbsd.org> | 2007-06-10 10:53:50 +0000 |
---|---|---|
committer | Marc Balmer <mbalmer@cvs.openbsd.org> | 2007-06-10 10:53:50 +0000 |
commit | ee0f444043f62b1989c63b9419c2e908f6c4793f (patch) | |
tree | 7d1c958fdcad64480efcbfb6f0ea69602208ab47 /sys/dev/usb/ugen.c | |
parent | ba9346211f99b37c96aa619b9981b230c7b4a61d (diff) |
Remove the definition and use of the USBDEV macro. It only created confusion
and the address of it's argument: USBDEV(sc->sc_dev) yields &sc->sc_dev.
No binary changes.
ok jsg.
Diffstat (limited to 'sys/dev/usb/ugen.c')
-rw-r--r-- | sys/dev/usb/ugen.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/sys/dev/usb/ugen.c b/sys/dev/usb/ugen.c index 2d6ed69f777..054199e78e5 100644 --- a/sys/dev/usb/ugen.c +++ b/sys/dev/usb/ugen.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ugen.c,v 1.41 2007/06/06 19:25:49 mk Exp $ */ +/* $OpenBSD: ugen.c,v 1.42 2007/06/10 10:53:48 mbalmer Exp $ */ /* $NetBSD: ugen.c,v 1.63 2002/11/26 18:49:48 christos Exp $ */ /* $FreeBSD: src/sys/dev/usb/ugen.c,v 1.26 1999/11/17 22:33:41 n_hibma Exp $ */ @@ -194,7 +194,7 @@ ugen_attach(struct device *parent, struct device *self, void *aux) } usbd_add_drv_event(USB_EVENT_DRIVER_ATTACH, sc->sc_udev, - USBDEV(sc->sc_dev)); + &sc->sc_dev); } int @@ -618,7 +618,7 @@ ugenread(dev_t dev, struct uio *uio, int flag) sc->sc_refcnt++; error = ugen_do_read(sc, endpt, uio, flag); if (--sc->sc_refcnt < 0) - usb_detach_wakeup(USBDEV(sc->sc_dev)); + usb_detach_wakeup(&sc->sc_dev); return (error); } @@ -717,7 +717,7 @@ ugenwrite(dev_t dev, struct uio *uio, int flag) sc->sc_refcnt++; error = ugen_do_write(sc, endpt, uio, flag); if (--sc->sc_refcnt < 0) - usb_detach_wakeup(USBDEV(sc->sc_dev)); + usb_detach_wakeup(&sc->sc_dev); return (error); } @@ -764,7 +764,7 @@ ugen_detach(struct device *self, int flags) for (i = 0; i < USB_MAX_ENDPOINTS; i++) wakeup(&sc->sc_endpoints[i][IN]); /* Wait for processes to go away. */ - usb_detach_wait(USBDEV(sc->sc_dev)); + usb_detach_wait(&sc->sc_dev); } splx(s); @@ -778,7 +778,7 @@ ugen_detach(struct device *self, int flags) vdevgone(maj, mn, mn + USB_MAX_ENDPOINTS - 1, VCHR); usbd_add_drv_event(USB_EVENT_DRIVER_DETACH, sc->sc_udev, - USBDEV(sc->sc_dev)); + &sc->sc_dev); return (0); } @@ -1263,7 +1263,7 @@ ugenioctl(dev_t dev, u_long cmd, caddr_t addr, int flag, usb_proc_ptr p) sc->sc_refcnt++; error = ugen_do_ioctl(sc, endpt, cmd, addr, flag, p); if (--sc->sc_refcnt < 0) - usb_detach_wakeup(USBDEV(sc->sc_dev)); + usb_detach_wakeup(&sc->sc_dev); return (error); } |