svn commit: r187577 - stable/7/sys/dev/usb

Nick Hibma n_hibma at FreeBSD.org
Wed Jan 21 15:10:44 PST 2009


Author: n_hibma
Date: Wed Jan 21 23:10:43 2009
New Revision: 187577
URL: http://svn.freebsd.org/changeset/base/187577

Log:
  Sync this file with HEAD r183874.
  - Remove a redundant MOD_LOAD function
  - Reduce the attach priority for the attach function to give other
    drivers, like the to be committed u3g driver a better chance at
    attaching to the 3G devices with a ZeroCD / TruInstall mass storage
    device.

Modified:
  stable/7/sys/dev/usb/umass.c

Modified: stable/7/sys/dev/usb/umass.c
==============================================================================
--- stable/7/sys/dev/usb/umass.c	Wed Jan 21 23:10:06 2009	(r187576)
+++ stable/7/sys/dev/usb/umass.c	Wed Jan 21 23:10:43 2009	(r187577)
@@ -574,6 +574,10 @@ static struct umass_devdescr_t umass_dev
 	  UMASS_PROTO_SCSI | UMASS_PROTO_BBB,
 	  NO_INQUIRY
 	},
+	{ USB_VENDOR_NETAC, USB_PRODUCT_NETAC_ONLYDISK, RID_WILDCARD,
+	  UMASS_PROTO_SCSI | UMASS_PROTO_BBB,
+	  IGNORE_RESIDUE
+	},
 	{ USB_VENDOR_NETCHIP, USB_PRODUCT_NETCHIP_CLIK_40, RID_WILDCARD,
 	  UMASS_PROTO_ATAPI,
 	  NO_INQUIRY
@@ -606,6 +610,10 @@ static struct umass_devdescr_t umass_dev
 	  UMASS_PROTO_SCSI,
 	  NO_QUIRKS
 	},
+	{ USB_VENDOR_ONSPEC, USB_PRODUCT_ONSPEC_SDS_HOTFIND_D, RID_WILDCARD,
+	  UMASS_PROTO_SCSI | UMASS_PROTO_BBB,
+	  NO_GETMAXLUN | NO_SYNCHRONIZE_CACHE
+	},
 	{ USB_VENDOR_ONSPEC, USB_PRODUCT_ONSPEC_MDCFE_B_CF_READER, RID_WILDCARD,
 	  UMASS_PROTO_SCSI,
 	  NO_QUIRKS
@@ -1264,7 +1272,7 @@ umass_match_proto(struct umass_softc *sc
 		return(UMATCH_NONE);
 	}
 
-	return(UMATCH_DEVCLASS_DEVSUBCLASS_DEVPROTO);
+	return(UMATCH_IFACECLASS_IFACESUBCLASS_IFACEPROTO);
 }
 
 static int
@@ -1276,6 +1284,7 @@ umass_match(device_t self)
 	sc->sc_dev = self;
 	if (uaa->iface == NULL)
 		return(UMATCH_NONE);
+	
 	return(umass_match_proto(sc, uaa->iface, uaa->device));
 }
 
@@ -3276,17 +3285,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
  */
@@ -3526,7 +3524,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-all mailing list