PERFORCE change 157618 for review

Hans Petter Selasky hselasky at FreeBSD.org
Thu Feb 12 15:34:56 PST 2009


http://perforce.freebsd.org/chv.cgi?CH=157618

Change 157618 by hselasky at hselasky_laptop001 on 2009/02/12 23:34:24

	
	USB WLAN: Re-introduce fix for failing control transfers after
	firmware load. Repeat the transfer until a) detach or b) success.

Affected files ...

.. //depot/projects/usb/src/sys/dev/usb2/wlan/if_rum2.c#41 edit
.. //depot/projects/usb/src/sys/dev/usb2/wlan/if_ural2.c#40 edit

Differences ...

==== //depot/projects/usb/src/sys/dev/usb2/wlan/if_rum2.c#41 (text+ko) ====

@@ -588,14 +588,15 @@
     struct usb2_device_request *req, void *data)
 {
 	usb2_error_t err;
-
+retry:
 	err = usb2_do_request_proc(sc->sc_udev, &sc->sc_tq, 
-	   req, data, 0, NULL, 1000 /* ms */);
+	   req, data, 0, NULL, 250 /* ms */);
 
 	if (err) {
 		DPRINTFN(1, "Control request failed, "
 		    "%s! (ignored)\n", usb2_errstr(err));
-		rum_pause(sc, hz / 100);
+		if ((sc->sc_ifp != NULL) && (!rum_pause(sc, hz / 100)))
+			goto retry;
 	}
 	return (err);
 }

==== //depot/projects/usb/src/sys/dev/usb2/wlan/if_ural2.c#40 (text+ko) ====

@@ -579,13 +579,15 @@
     struct usb2_device_request *req, void *data)
 {
 	usb2_error_t err;
-
+retry:
 	err = usb2_do_request_proc(sc->sc_udev, &sc->sc_tq, 
-	   req, data, 0, NULL, 1000 /* ms */);
+	   req, data, 0, NULL, 250 /* ms */);
 
 	if (err) {
-		DPRINTFN(1, "Control request failed! (ignored)\n");
-		ural_pause(sc, hz / 100);
+		DPRINTFN(1, "Control request failed, "
+		    "%s! (ignored)\n", usb2_errstr(err));
+		if ((sc->sc_ifp != NULL) && (!ural_pause(sc, hz / 100)))
+			goto retry;
 	}
 }
 


More information about the p4-projects mailing list