[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230420111445.5028-1-WeitaoWang-oc@zhaoxin.com>
Date: Thu, 20 Apr 2023 19:14:45 +0800
From: Weitao Wang <WeitaoWang-oc@...oxin.com>
To: <stern@...land.harvard.edu>, <gregkh@...uxfoundation.org>,
<linux-usb@...r.kernel.org>, <linux-kernel@...r.kernel.org>
CC: <tonywwang@...oxin.com>, <weitaowang@...oxin.com>
Subject: [PATCH] UHCI:adjust zhaoxin UHCI controllers OverCurrent bit value
Over Current condition is not standardized in the UHCI spec.
Zhaoxin UHCI controllers report OverCurrent bit active off.
Intel controllers report it active on, so we'll adjust the bit value.
Signed-off-by: Weitao Wang <WeitaoWang-oc@...oxin.com>
---
drivers/usb/host/uhci-pci.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/usb/host/uhci-pci.c b/drivers/usb/host/uhci-pci.c
index 3592f757fe05..177e3c2aa287 100644
--- a/drivers/usb/host/uhci-pci.c
+++ b/drivers/usb/host/uhci-pci.c
@@ -126,6 +126,10 @@ static int uhci_pci_init(struct usb_hcd *hcd)
if (to_pci_dev(uhci_dev(uhci))->vendor == PCI_VENDOR_ID_VIA)
uhci->oc_low = 1;
+ /* ZHAOXIN controllers report OverCurrent bit active off. */
+ if (to_pci_dev(uhci_dev(uhci))->vendor == PCI_VENDOR_ID_ZHAOXIN)
+ uhci->oc_low = 1;
+
/* HP's server management chip requires a longer port reset delay. */
if (to_pci_dev(uhci_dev(uhci))->vendor == PCI_VENDOR_ID_HP)
uhci->wait_for_hp = 1;
--
2.32.0
Powered by blists - more mailing lists