usb: diag_bridge: Treat EPROTO as a non-recoverable error
When a read or write callback returns -EPROTO, treat it as if the
device is disconnected and disallow further calls to read and write
by returning -ESHUTDOWN. This will allow the caller to gracefully
handle the error until a disconnect event finally comes and is able
to notify the caller via a platform_device removal.
Change-Id: I65cab1ea94e529743cba695e3c510c501a0e388e
Signed-off-by:
Jack Pham <jackp@codeaurora.org>
Loading
Please sign in to comment