From: Johan Hovold Date: Mon, 26 May 2014 17:23:49 +0000 (+0200) Subject: USB: cdc-acm: do not update PM busy on read errors X-Git-Tag: MMI-PSA29.97-13-9~11772^2~37^2~82 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=4a8ee5059a241114c644350b6cb564c729a340fa;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git USB: cdc-acm: do not update PM busy on read errors There's no need to update the runtime PM last_busy field on read urb errors (e.g. when the urb is being killed on shutdown). Signed-off-by: Johan Hovold Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/usb/class/cdc-acm.c b/drivers/usb/class/cdc-acm.c index f038f390db97..3c7cfac48e30 100644 --- a/drivers/usb/class/cdc-acm.c +++ b/drivers/usb/class/cdc-acm.c @@ -416,13 +416,15 @@ static void acm_read_bulk_callback(struct urb *urb) dev_dbg(&acm->data->dev, "%s - disconnected\n", __func__); return; } - usb_mark_last_busy(acm->dev); if (urb->status) { dev_dbg(&acm->data->dev, "%s - non-zero urb status: %d\n", __func__, urb->status); return; } + + usb_mark_last_busy(acm->dev); + acm_process_read_urb(acm, urb); /* throttle device if requested by tty */