From: Sarah Sharp Date: Wed, 11 Nov 2009 18:28:40 +0000 (-0800) Subject: USB: xhci: Return success for vendor-specific info codes. X-Git-Tag: v2.6.33-rc1~315^2~46 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5ad6a529c28db36010ec56c5ee8120addc712b51;p=profile%2Fivi%2Fkernel-adaptation-intel-automotive.git USB: xhci: Return success for vendor-specific info codes. An xHCI host controller manufacturer can choose to implement several vendor-specific informational completion codes. These are all to be treated like a successful transfer completion. Signed-off-by: Sarah Sharp Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c index 98437ff..1549b9c 100644 --- a/drivers/usb/host/xhci-ring.c +++ b/drivers/usb/host/xhci-ring.c @@ -1153,6 +1153,16 @@ static int handle_tx_event(struct xhci_hcd *xhci, status = -ENOSR; break; default: + if (trb_comp_code >= 224 && trb_comp_code <= 255) { + /* Vendor defined "informational" completion code, + * treat as not-an-error. + */ + xhci_dbg(xhci, "Vendor defined info completion code %u\n", + trb_comp_code); + xhci_dbg(xhci, "Treating code as success.\n"); + status = 0; + break; + } xhci_warn(xhci, "ERROR Unknown event condition, HC probably busted\n"); urb = NULL; goto cleanup;