diff options
author | Kris Borer <kborer@gmail.com> | 2015-08-11 11:12:45 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-08-14 16:54:02 -0700 |
commit | 088a3daeadf6f4123f54d5208b0ec7cbbfc8853f (patch) | |
tree | 63d485291e4fb6c357e075dd0efc541971161fd8 /drivers/usb/core | |
parent | e3ec4fda072c72c8ed014b58a3a4dd54b2b454bd (diff) | |
download | linux-088a3daeadf6f4123f54d5208b0ec7cbbfc8853f.tar.bz2 |
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:
// <smpl>
@@
identifier i;
expression E, E2, E3;
statement S1, S2;
binary operator b;
@@
+ i = E;
if (
- (i = E)
+ i
b
... && E2 && E3 ) S1 else S2
// </smpl>
Signed-off-by: Kris Borer <kborer@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/core')
-rw-r--r-- | drivers/usb/core/hub.c | 4 |
1 files 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); } |