aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host
diff options
context:
space:
mode:
authorDavid Brownell <david-b@pacbell.net>2005-04-18 20:39:30 -0400
committerGreg K-H <gregkh@suse.de>2005-04-18 20:39:30 -0400
commit0e4987639a774d08b69c1c58774f3430f6083d4f (patch)
treed9d9eb475b11c05b069c715df50f9e6d89c32ecf /drivers/usb/host
parenta2fe20129e2d87dc5c4e5c850b41b5b0b47cfd08 (diff)
[PATCH] USB: OHCI on Compaq Aramada 7400
This adds a quirk to the OHCI driver that lets it work with an old Compaq implementation. It also removes some needless strings from the non-debug version of the driver. Signed-off-by: Chris Clayton <chris_clayton@f1internet.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/host')
-rw-r--r--drivers/usb/host/ohci-pci.c17
-rw-r--r--drivers/usb/host/ohci-q.c13
-rw-r--r--drivers/usb/host/ohci.h1
3 files changed, 26 insertions, 5 deletions
diff --git a/drivers/usb/host/ohci-pci.c b/drivers/usb/host/ohci-pci.c
index f30118b5f9aa..57fd07d00549 100644
--- a/drivers/usb/host/ohci-pci.c
+++ b/drivers/usb/host/ohci-pci.c
@@ -54,7 +54,7 @@ ohci_pci_start (struct usb_hcd *hcd)
54 if (pdev->vendor == PCI_VENDOR_ID_AMD 54 if (pdev->vendor == PCI_VENDOR_ID_AMD
55 && pdev->device == 0x740c) { 55 && pdev->device == 0x740c) {
56 ohci->flags = OHCI_QUIRK_AMD756; 56 ohci->flags = OHCI_QUIRK_AMD756;
57 ohci_info (ohci, "AMD756 erratum 4 workaround\n"); 57 ohci_dbg (ohci, "AMD756 erratum 4 workaround\n");
58 // also somewhat erratum 10 (suspend/resume issues) 58 // also somewhat erratum 10 (suspend/resume issues)
59 } 59 }
60 60
@@ -68,7 +68,7 @@ ohci_pci_start (struct usb_hcd *hcd)
68 */ 68 */
69 else if (pdev->vendor == PCI_VENDOR_ID_OPTI 69 else if (pdev->vendor == PCI_VENDOR_ID_OPTI
70 && pdev->device == 0xc861) { 70 && pdev->device == 0xc861) {
71 ohci_info (ohci, 71 ohci_dbg (ohci,
72 "WARNING: OPTi workarounds unavailable\n"); 72 "WARNING: OPTi workarounds unavailable\n");
73 } 73 }
74 74
@@ -84,9 +84,20 @@ ohci_pci_start (struct usb_hcd *hcd)
84 if (b && b->device == PCI_DEVICE_ID_NS_87560_LIO 84 if (b && b->device == PCI_DEVICE_ID_NS_87560_LIO
85 && b->vendor == PCI_VENDOR_ID_NS) { 85 && b->vendor == PCI_VENDOR_ID_NS) {
86 ohci->flags |= OHCI_QUIRK_SUPERIO; 86 ohci->flags |= OHCI_QUIRK_SUPERIO;
87 ohci_info (ohci, "Using NSC SuperIO setup\n"); 87 ohci_dbg (ohci, "Using NSC SuperIO setup\n");
88 } 88 }
89 } 89 }
90
91 /* Check for Compaq's ZFMicro chipset, which needs short
92 * delays before control or bulk queues get re-activated
93 * in finish_unlinks()
94 */
95 else if (pdev->vendor == PCI_VENDOR_ID_COMPAQ
96 && pdev->device == 0xa0f8) {
97 ohci->flags |= OHCI_QUIRK_ZFMICRO;
98 ohci_dbg (ohci,
99 "enabled Compaq ZFMicro chipset quirk\n");
100 }
90 } 101 }
91 102
92 /* NOTE: there may have already been a first reset, to 103 /* NOTE: there may have already been a first reset, to
diff --git a/drivers/usb/host/ohci-q.c b/drivers/usb/host/ohci-q.c
index c90114a77277..e372306ed0da 100644
--- a/drivers/usb/host/ohci-q.c
+++ b/drivers/usb/host/ohci-q.c
@@ -1021,6 +1021,8 @@ rescan_this:
1021 1021
1022 if (ohci->ed_controltail) { 1022 if (ohci->ed_controltail) {
1023 command |= OHCI_CLF; 1023 command |= OHCI_CLF;
1024 if (ohci->flags & OHCI_QUIRK_ZFMICRO)
1025 mdelay(1);
1024 if (!(ohci->hc_control & OHCI_CTRL_CLE)) { 1026 if (!(ohci->hc_control & OHCI_CTRL_CLE)) {
1025 control |= OHCI_CTRL_CLE; 1027 control |= OHCI_CTRL_CLE;
1026 ohci_writel (ohci, 0, 1028 ohci_writel (ohci, 0,
@@ -1029,6 +1031,8 @@ rescan_this:
1029 } 1031 }
1030 if (ohci->ed_bulktail) { 1032 if (ohci->ed_bulktail) {
1031 command |= OHCI_BLF; 1033 command |= OHCI_BLF;
1034 if (ohci->flags & OHCI_QUIRK_ZFMICRO)
1035 mdelay(1);
1032 if (!(ohci->hc_control & OHCI_CTRL_BLE)) { 1036 if (!(ohci->hc_control & OHCI_CTRL_BLE)) {
1033 control |= OHCI_CTRL_BLE; 1037 control |= OHCI_CTRL_BLE;
1034 ohci_writel (ohci, 0, 1038 ohci_writel (ohci, 0,
@@ -1039,12 +1043,17 @@ rescan_this:
1039 /* CLE/BLE to enable, CLF/BLF to (maybe) kickstart */ 1043 /* CLE/BLE to enable, CLF/BLF to (maybe) kickstart */
1040 if (control) { 1044 if (control) {
1041 ohci->hc_control |= control; 1045 ohci->hc_control |= control;
1046 if (ohci->flags & OHCI_QUIRK_ZFMICRO)
1047 mdelay(1);
1042 ohci_writel (ohci, ohci->hc_control, 1048 ohci_writel (ohci, ohci->hc_control,
1043 &ohci->regs->control); 1049 &ohci->regs->control);
1044 } 1050 }
1045 if (command) 1051 if (command) {
1052 if (ohci->flags & OHCI_QUIRK_ZFMICRO)
1053 mdelay(1);
1046 ohci_writel (ohci, command, &ohci->regs->cmdstatus); 1054 ohci_writel (ohci, command, &ohci->regs->cmdstatus);
1047 } 1055 }
1056 }
1048} 1057}
1049 1058
1050 1059
diff --git a/drivers/usb/host/ohci.h b/drivers/usb/host/ohci.h
index 2ba6e2b0210c..22e1ac138ac0 100644
--- a/drivers/usb/host/ohci.h
+++ b/drivers/usb/host/ohci.h
@@ -396,6 +396,7 @@ struct ohci_hcd {
396#define OHCI_QUIRK_SUPERIO 0x02 /* natsemi */ 396#define OHCI_QUIRK_SUPERIO 0x02 /* natsemi */
397#define OHCI_QUIRK_INITRESET 0x04 /* SiS, OPTi, ... */ 397#define OHCI_QUIRK_INITRESET 0x04 /* SiS, OPTi, ... */
398#define OHCI_BIG_ENDIAN 0x08 /* big endian HC */ 398#define OHCI_BIG_ENDIAN 0x08 /* big endian HC */
399#define OHCI_QUIRK_ZFMICRO 0x10 /* Compaq ZFMicro chipset*/
399 // there are also chip quirks/bugs in init logic 400 // there are also chip quirks/bugs in init logic
400 401
401}; 402};