Re: [PATCH 22/25] usb: host: xhci: remove unnecessary list_for_each_entry_safe()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello!

On 12/1/2016 4:31 PM, Felipe Balbi wrote:

the _save() version of list iterators are supposed to be used when

   _safe().

list_entry is going to be removed from the list while iterating. Since
xhci_handle_stopped_cmd_ring() is not removing anything from the list,
just converting commands into No-Op TRBs, we don't need to use the safe
version.

Signed-off-by: Felipe Balbi <felipe.balbi@xxxxxxxxxxxxxxx>
---
 drivers/usb/host/xhci-ring.c | 21 ++++++++++-----------
 1 file changed, 10 insertions(+), 11 deletions(-)

diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c
index 50244dee6b43..ebb52ffab805 100644
--- a/drivers/usb/host/xhci-ring.c
+++ b/drivers/usb/host/xhci-ring.c
[...]
@@ -1250,7 +1250,6 @@ static void xhci_handle_stopped_cmd_ring(struct xhci_hcd *xhci,
 		mod_timer(&xhci->cmd_timer, jiffies + XHCI_CMD_DEFAULT_TIMEOUT);
 		xhci_ring_cmd_db(xhci);
 	}
-	return;

   Not mentioned in the patch description?

 }



MBR, Sergei

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux