projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
78f74f7
)
usb: misc: remove unnecessary code
author
Gustavo A. R. Silva
<
[email protected]
>
Thu, 16 Feb 2017 21:25:44 +0000
(15:25 -0600)
committer
Greg Kroah-Hartman
<
[email protected]
>
Thu, 16 Mar 2017 08:58:44 +0000
(17:58 +0900)
'val' is an unsigned variable, and less-than-zero comparison of an unsigned
variable is never true.
Addresses-Coverity-ID:
1230256
Signed-off-by: Gustavo A. R. Silva <
[email protected]
>
Signed-off-by: Greg Kroah-Hartman <
[email protected]
>
drivers/usb/misc/lvstest.c
patch
|
blob
|
history
diff --git
a/drivers/usb/misc/lvstest.c
b/drivers/usb/misc/lvstest.c
index 77176511658f3328f830ecdbd056f072a6c84f8a..c7c210421217b228574e4565b7200600d2856814 100644
(file)
--- a/
drivers/usb/misc/lvstest.c
+++ b/
drivers/usb/misc/lvstest.c
@@
-222,7
+222,7
@@
static ssize_t u1_timeout_store(struct device *dev,
return ret;
}
- if (val
< 0 || val
> 127)
+ if (val > 127)
return -EINVAL;
ret = lvs_rh_set_port_feature(hdev, lvs->portnum | (val << 8),