svn commit: r183734 - head/sys/dev/usb
Nick Hibma
n_hibma at FreeBSD.org
Thu Oct 9 20:51:28 UTC 2008
Author: n_hibma
Date: Thu Oct 9 20:51:25 2008
New Revision: 183734
URL: http://svn.freebsd.org/changeset/base/183734
Log:
uark/ucom: Minor code cleanup.
umass; Remove duplicated code.
ukbd: Fill in the arg parameter on the through call.
Modified:
head/sys/dev/usb/uark.c
head/sys/dev/usb/ucom.c
head/sys/dev/usb/ukbd.c
head/sys/dev/usb/umass.c
Modified: head/sys/dev/usb/uark.c
==============================================================================
--- head/sys/dev/usb/uark.c Thu Oct 9 20:43:42 2008 (r183733)
+++ head/sys/dev/usb/uark.c Thu Oct 9 20:51:25 2008 (r183734)
@@ -185,7 +185,7 @@ uark_attach(device_t self)
return 0;
bad:
- DPRINTF(("uftdi_attach: ATTACH ERROR\n"));
+ DPRINTF(("uark_attach: ATTACH ERROR\n"));
ucom->sc_dying = 1;
return ENXIO;
}
Modified: head/sys/dev/usb/ucom.c
==============================================================================
--- head/sys/dev/usb/ucom.c Thu Oct 9 20:43:42 2008 (r183733)
+++ head/sys/dev/usb/ucom.c Thu Oct 9 20:51:25 2008 (r183734)
@@ -161,14 +161,11 @@ ucom_modevent(module_t mod, int type, vo
{
switch (type) {
case MOD_LOAD:
- break;
case MOD_UNLOAD:
- break;
+ return (0);
default:
return (EOPNOTSUPP);
- break;
}
- return (0);
}
void
Modified: head/sys/dev/usb/ukbd.c
==============================================================================
--- head/sys/dev/usb/ukbd.c Thu Oct 9 20:43:42 2008 (r183733)
+++ head/sys/dev/usb/ukbd.c Thu Oct 9 20:51:25 2008 (r183734)
@@ -1534,5 +1534,5 @@ ukbd_driver_load(module_t mod, int what,
kbd_delete_driver(&ukbd_kbd_driver);
break;
}
- return usbd_driver_load(mod, what, 0);
+ return usbd_driver_load(mod, what, arg);
}
Modified: head/sys/dev/usb/umass.c
==============================================================================
--- head/sys/dev/usb/umass.c Thu Oct 9 20:43:42 2008 (r183733)
+++ head/sys/dev/usb/umass.c Thu Oct 9 20:51:25 2008 (r183734)
@@ -3291,17 +3291,6 @@ umass_cam_quirk_cb(struct umass_softc *s
xpt_done(ccb);
}
-static int
-umass_driver_load(module_t mod, int what, void *arg)
-{
- switch (what) {
- case MOD_UNLOAD:
- case MOD_LOAD:
- default:
- return(usbd_driver_load(mod, what, arg));
- }
-}
-
/*
* SCSI specific functions
*/
@@ -3541,7 +3530,7 @@ umass_atapi_transform(struct umass_softc
/* (even the comment is missing) */
-DRIVER_MODULE(umass, uhub, umass_driver, umass_devclass, umass_driver_load, 0);
+DRIVER_MODULE(umass, uhub, umass_driver, umass_devclass, usbd_driver_load, 0);
More information about the svn-src-head
mailing list