Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 26 Dec 2007 10:49:47 GMT
From:      Hans Petter Selasky <hselasky@FreeBSD.org>
To:        Perforce Change Reviews <perforce@FreeBSD.org>
Subject:   PERFORCE change 131677 for review
Message-ID:  <200712261049.lBQAnlg9074531@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=131677

Change 131677 by hselasky@hselasky_laptop001 on 2007/12/26 10:49:01

	
	Style change by "usb_style.sh".

Affected files ...

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

Differences ...

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

@@ -2492,7 +2492,6 @@
 		/* tearing down */
 		return;
 	}
-
 	mtx_assert(xfer->priv_mtx, MA_OWNED);
 
 	/* avoid any races by locking the USB mutex */
@@ -2518,7 +2517,6 @@
 		/* tearing down */
 		return;
 	}
-
 	mtx_assert(xfer->priv_mtx, MA_OWNED);
 
 	/* avoid any races by locking the USB mutex */
@@ -2577,22 +2575,22 @@
 	 * Check if we are supposed to stall the pipe:
 	 */
 	if (xfer->flags.stall_pipe) {
-			/* clear stall command */
-			xfer->flags.stall_pipe = 0;
+		/* clear stall command */
+		xfer->flags.stall_pipe = 0;
 
-	    if (xfer->flags_int.usb_mode == USB_MODE_DEVICE) {
-		/*
-		 * Only stall BULK and INTERRUPT endpoints.
-		 */
-		type = (xfer->pipe->edesc->bmAttributes & UE_XFERTYPE);
-		if ((type == UE_BULK) ||
-		    (type == UE_INTERRUPT)) {
-			xfer->pipe->is_stalled = 1;
-			(xfer->udev->bus->methods->set_stall) (
-			    xfer->udev, NULL, xfer->pipe);
-			goto done;
+		if (xfer->flags_int.usb_mode == USB_MODE_DEVICE) {
+			/*
+			 * Only stall BULK and INTERRUPT endpoints.
+			 */
+			type = (xfer->pipe->edesc->bmAttributes & UE_XFERTYPE);
+			if ((type == UE_BULK) ||
+			    (type == UE_INTERRUPT)) {
+				xfer->pipe->is_stalled = 1;
+				(xfer->udev->bus->methods->set_stall) (
+				    xfer->udev, NULL, xfer->pipe);
+				goto done;
+			}
 		}
-	    }
 	}
 	/*
 	 * Handled cases:
@@ -2889,8 +2887,8 @@
  * send STALL tokens.
  *------------------------------------------------------------------------*/
 static usbd_status_t
-usbd_handle_set_stall_sub(struct usbd_device *udev, uint8_t ea_val, 
-uint8_t do_stall)
+usbd_handle_set_stall_sub(struct usbd_device *udev, uint8_t ea_val,
+    uint8_t do_stall)
 {
 	struct usbd_pipe *pipe;
 	struct usbd_xfer *xfer;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200712261049.lBQAnlg9074531>