From: Felipe Balbi Date: Thu, 26 Feb 2015 16:55:13 +0000 (-0600) Subject: usb: musb: dsps: return error code if reset fails X-Git-Tag: v4.1-rc1~154^2~55^2~98 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=d0cddae7926f39e8fd488f62496cfebf7a5e757d;p=linux.git usb: musb: dsps: return error code if reset fails if reset fails, we should return a *negative* error code, not a positive value. Tested-by: Bin Liu Signed-off-by: Felipe Balbi --- diff --git a/drivers/usb/musb/musb_dsps.c b/drivers/usb/musb/musb_dsps.c index a900c9877195..af614f49cd98 100644 --- a/drivers/usb/musb/musb_dsps.c +++ b/drivers/usb/musb/musb_dsps.c @@ -652,7 +652,7 @@ static int dsps_musb_reset(struct musb *musb) session_restart = 1; } - return !session_restart; + return session_restart ? 0 : -EPIPE; } static struct musb_platform_ops dsps_ops = {