From 088a3daeadf6f4123f54d5208b0ec7cbbfc8853f Mon Sep 17 00:00:00 2001 From: Kris Borer Date: Tue, 11 Aug 2015 11:12:45 -0400 Subject: [PATCH] usb: hub: remove assignment from if condition Fix one occurrence of the checkpatch.pl error: ERROR: do not use assignment in if condition The semantic patch that makes this change is: // @@ identifier i; expression E, E2, E3; statement S1, S2; binary operator b; @@ + i = E; if ( - (i = E) + i b ... && E2 && E3 ) S1 else S2 // Signed-off-by: Kris Borer Signed-off-by: Greg Kroah-Hartman --- drivers/usb/core/hub.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c index a0b22be1509d..78bd0d671d9a 100644 --- a/drivers/usb/core/hub.c +++ b/drivers/usb/core/hub.c @@ -671,8 +671,8 @@ resubmit: if (hub->quiescing) return; - if ((status = usb_submit_urb(hub->urb, GFP_ATOMIC)) != 0 - && status != -ENODEV && status != -EPERM) + status = usb_submit_urb(hub->urb, GFP_ATOMIC); + if (status != 0 && status != -ENODEV && status != -EPERM) dev_err(hub->intfdev, "resubmit --> %d\n", status); } -- 2.39.5