Commit 5bd7b419ef2eb4989b207753e088c3437159618a
Committed by
Greg Kroah-Hartman
1 parent
9426cd0568
Exists in
smarc-l5.0.0_1.0.0-ga
and in
5 other branches
uwb: fix error handling
Fatal errors such as a device disconnect must not trigger error handling. The error returns must be checked. Signed-off-by: Oliver Neukum <oneukum@suse.de> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Showing 1 changed file with 2 additions and 1 deletions Side-by-side Diff
drivers/uwb/hwa-rc.c
... | ... | @@ -645,7 +645,8 @@ |
645 | 645 | dev_err(dev, "NEEP: URB error %d\n", urb->status); |
646 | 646 | } |
647 | 647 | result = usb_submit_urb(urb, GFP_ATOMIC); |
648 | - if (result < 0) { | |
648 | + if (result < 0 && result != -ENODEV && result != -EPERM) { | |
649 | + /* ignoring unrecoverable errors */ | |
649 | 650 | dev_err(dev, "NEEP: Can't resubmit URB (%d) resetting device\n", |
650 | 651 | result); |
651 | 652 | goto error; |