PERFORCE change 130959 for review

Hans Petter Selasky hselasky at FreeBSD.org
Sat Dec 15 09:14:20 PST 2007


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

Change 130959 by hselasky at hselasky_laptop001 on 2007/12/15 17:13:42

	
	Style change by "usb_style.sh".

Affected files ...

.. //depot/projects/usb/src/sys/dev/usb/usb_transfer.c#72 edit

Differences ...

==== //depot/projects/usb/src/sys/dev/usb/usb_transfer.c#72 (text+ko) ====

@@ -1202,36 +1202,36 @@
 	xfer->usb_thread = td;
 
 	if (xfer->flags_int.control_xfr) {
-	  if (xfer->flags_int.control_hdr) {
+		if (xfer->flags_int.control_hdr) {
 
-		/* copy out the USB request */
+			/* copy out the USB request */
 
-		if (xfer->frlengths[0] == sizeof(std->req)) {
-			usbd_copy_out(xfer->frbuffers + 0, 0,
-			    &(std->req), sizeof(std->req));
-		} else {
-			std->err = USBD_INVAL;
-			goto done;
-		}
+			if (xfer->frlengths[0] == sizeof(std->req)) {
+				usbd_copy_out(xfer->frbuffers + 0, 0,
+				    &(std->req), sizeof(std->req));
+			} else {
+				std->err = USBD_INVAL;
+				goto done;
+			}
 
-		xfer->aframes = 1;
+			xfer->aframes = 1;
 
-		std->err = 0;
-		std->state = USBD_STD_ROOT_TR_SETUP;
+			std->err = 0;
+			std->state = USBD_STD_ROOT_TR_SETUP;
 
-		(func) (xfer, std);
+			(func) (xfer, std);
 
-		if (xfer->usb_thread != td) {
-			/* transfer cancelled */
-			goto done;
+			if (xfer->usb_thread != td) {
+				/* transfer cancelled */
+				goto done;
+			}
+			if (std->err) {
+				goto done;
+			}
+		} else {
+			/* skip the first frame in this case */
+			xfer->aframes = 1;
 		}
-		if (std->err) {
-			goto done;
-		}
-	  } else {
-	      /* skip the first frame in this case */
-	      xfer->aframes = 1;
-	  }
 	}
 	std->err = 0;
 	std->state = USBD_STD_ROOT_TR_PRE_DATA;


More information about the p4-projects mailing list