From d0cddae7926f39e8fd488f62496cfebf7a5e757d Mon Sep 17 00:00:00 2001 From: Felipe Balbi Date: Thu, 26 Feb 2015 10:55:13 -0600 Subject: [PATCH] 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 --- drivers/usb/musb/musb_dsps.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 = { -- 2.11.0