Commit 62de6e0a authored by Viresh Kumar's avatar Viresh Kumar Committed by Greg Kroah-Hartman

greybus: es2: don't protest when getting -ENOENT/ESHUTDOWN USB errors

-ENOENT or -ESHUTDOWN happens when the urbs are being killed from
->disconnect() callback.  Don't complain to userspace about this, as the
user will see this on es2 module removal.

Tested by removing the gb-es2.ko module on both EVT1.5 and qemu with
gbsim. The driver doesn't throw anymore errors like:
"urb cport in error -2 (dropped)".
Signed-off-by: default avatarViresh Kumar <viresh.kumar@linaro.org>
Tested-by: default avatarDavid Lin <dtwlin@google.com>
Reviewed-by: default avatarJohan Hovold <johan@hovoldconsulting.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@google.com>
parent ecdd3a2d
......@@ -715,6 +715,11 @@ static void cport_in_callback(struct urb *urb)
if (status) {
if ((status == -EAGAIN) || (status == -EPROTO))
goto exit;
/* The urb is being unlinked */
if (status == -ENOENT || status == -ESHUTDOWN)
return;
dev_err(dev, "urb cport in error %d (dropped)\n", status);
return;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment