diff options
author | Gustavo A. R. Silva <garsilva@embeddedor.com> | 2017-02-15 04:10:52 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-02-15 19:35:15 +0100 |
commit | 53b7f7b53d83727075c01f57f813fc141d53c3d5 (patch) | |
tree | f11002cf6b7c106456250e722d99225e87593e96 /drivers/usb/class/cdc-wdm.c | |
parent | usb: musb: add code comment for clarification (diff) | |
download | linux-53b7f7b53d83727075c01f57f813fc141d53c3d5.tar.xz linux-53b7f7b53d83727075c01f57f813fc141d53c3d5.zip |
usb: cdc-wdm: remove logically dead code
Remove logically dead code.
'cntr' is always equal to zero when the following line of code is executed:
rv = cntr ? cntr : -EAGAIN;
Addresses-Coverity-ID: 113227
Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Acked-by: Oliver Neukum <oneukum@suse.com>
Reviewed-by: Peter Senna Tschudin <peter.senna@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/class/cdc-wdm.c')
-rw-r--r-- | drivers/usb/class/cdc-wdm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/class/cdc-wdm.c b/drivers/usb/class/cdc-wdm.c index 0a6369510f2d..8fda45a45bd3 100644 --- a/drivers/usb/class/cdc-wdm.c +++ b/drivers/usb/class/cdc-wdm.c @@ -531,7 +531,7 @@ retry: i++; if (file->f_flags & O_NONBLOCK) { if (!test_bit(WDM_READ, &desc->flags)) { - rv = cntr ? cntr : -EAGAIN; + rv = -EAGAIN; goto err; } rv = 0; |