Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 88a1e909 authored by Alexander Beregalov's avatar Alexander Beregalov Committed by Greg Kroah-Hartman
Browse files

Staging: usbip: switch to list_for_each_entry()

parent 8cc59061
Loading
Loading
Loading
Loading
+1 −4
Original line number Diff line number Diff line
@@ -234,8 +234,6 @@ static void tweak_special_requests(struct urb *urb)
static int stub_recv_cmd_unlink(struct stub_device *sdev,
						struct usbip_header *pdu)
{
	struct list_head *listhead = &sdev->priv_init;
	struct list_head *ptr;
	unsigned long flags;

	struct stub_priv *priv;
@@ -243,8 +241,7 @@ static int stub_recv_cmd_unlink(struct stub_device *sdev,

	spin_lock_irqsave(&sdev->priv_lock, flags);

	for (ptr = listhead->next; ptr != listhead; ptr = ptr->next) {
		priv = list_entry(ptr, struct stub_priv, list);
	list_for_each_entry(priv, &sdev->priv_init, list) {
		if (priv->seqnum == pdu->u.cmd_unlink.seqnum) {
			int ret;