From: Matt Porter Date: Mon, 13 Oct 2014 07:00:53 +0000 (-0400) Subject: greybus: es1-ap-usb: handle -EPROTO in check_urb_status() X-Git-Tag: v4.9-rc1~119^2~378^2~21^2~2020 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=8fd39e3dcb881501726ed0161855ed7a61f642ef;p=karo-tx-linux.git greybus: es1-ap-usb: handle -EPROTO in check_urb_status() On a disconnect we can also have a status of -EPROTO. This results in a flood of error messages due to the -EAGAIN handling of unsupported status results. Fix this by also returning status when we have -EPROTO. Signed-off-by: Matt Porter Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/greybus/es1-ap-usb.c b/drivers/staging/greybus/es1-ap-usb.c index 97dd9b6a2bc1..1a67d9e15c2a 100644 --- a/drivers/staging/greybus/es1-ap-usb.c +++ b/drivers/staging/greybus/es1-ap-usb.c @@ -257,6 +257,7 @@ static int check_urb_status(struct urb *urb) case -ENOENT: case -ESHUTDOWN: case -EILSEQ: + case -EPROTO: /* device is gone, stop sending */ return status; }