From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932571AbcCRMeS (ORCPT ); Fri, 18 Mar 2016 08:34:18 -0400 Received: from comal.ext.ti.com ([198.47.26.152]:36786 "EHLO comal.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932489AbcCRMeP (ORCPT ); Fri, 18 Mar 2016 08:34:15 -0400 From: Roger Quadros To: , CC: , , , Roger Quadros Subject: [PATCH 5/5] usb: dwc3: host: pass BROKEN_PE flag for known broken revisions Date: Fri, 18 Mar 2016 14:33:57 +0200 Message-ID: <1458304437-1210-6-git-send-email-rogerq@ti.com> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1458304437-1210-1-git-send-email-rogerq@ti.com> References: <1458304437-1210-1-git-send-email-rogerq@ti.com> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Felipe Balbi Now that we have a broken pe quirk flag, dwc3 can tell XHCI core about it. Signed-off-by: Felipe Balbi Signed-off-by: Sekhar Nori Signed-off-by: Roger Quadros --- drivers/usb/dwc3/host.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/drivers/usb/dwc3/host.c b/drivers/usb/dwc3/host.c index c679f63..db9347b 100644 --- a/drivers/usb/dwc3/host.c +++ b/drivers/usb/dwc3/host.c @@ -51,6 +51,18 @@ int dwc3_host_init(struct dwc3 *dwc) pdata.usb3_lpm_capable = dwc->usb3_lpm_capable; + /** + * WORKAROUND: dwc3 revisions <=3.00a have a limitation + * where Port Disable command doesn't work. + * + * The suggested workaround is that we avoid Port Disable + * completely. + * + * This following flag tells XHCI to do just that. + */ + if (dwc->revision <= DWC3_REVISION_300A) + pdata.quirk_port_broken_pe = true; + ret = platform_device_add_data(xhci, &pdata, sizeof(pdata)); if (ret) { dev_err(dwc->dev, "couldn't add platform data to xHCI device\n"); -- 2.5.0