From 1133cd8adf34709e1857d1491e9fae5597b51ad5 Mon Sep 17 00:00:00 2001 From: Dmitry Baryshkov Date: Sun, 6 Jul 2008 23:35:01 +0400 Subject: USB: ohci: make distrust_firmware a quirk Signed-off-by: Dmitry Baryshkov Acked-by: David Brownell Cc: Alan Stern Signed-off-by: Greg Kroah-Hartman --- drivers/usb/host/ohci-hcd.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'drivers/usb/host/ohci-hcd.c') diff --git a/drivers/usb/host/ohci-hcd.c b/drivers/usb/host/ohci-hcd.c index 26bc47941d0..96fe76e9a6c 100644 --- a/drivers/usb/host/ohci-hcd.c +++ b/drivers/usb/host/ohci-hcd.c @@ -483,6 +483,9 @@ static int ohci_init (struct ohci_hcd *ohci) int ret; struct usb_hcd *hcd = ohci_to_hcd(ohci); + if (distrust_firmware) + ohci->flags |= OHCI_QUIRK_HUB_POWER; + disable (ohci); ohci->regs = hcd->regs; @@ -689,7 +692,8 @@ retry: temp |= RH_A_NOCP; temp &= ~(RH_A_POTPGT | RH_A_NPS); ohci_writel (ohci, temp, &ohci->regs->roothub.a); - } else if ((ohci->flags & OHCI_QUIRK_AMD756) || distrust_firmware) { + } else if ((ohci->flags & OHCI_QUIRK_AMD756) || + (ohci->flags & OHCI_QUIRK_HUB_POWER)) { /* hub power always on; required for AMD-756 and some * Mac platforms. ganged overcurrent reporting, if any. */ -- cgit v1.2.3 From ab1666c1364a209e6141d7c14e47a42b5f00eca2 Mon Sep 17 00:00:00 2001 From: Libin Yang Date: Fri, 8 Aug 2008 15:03:31 +0800 Subject: USB: quirk PLL power down mode On some AMD 700 series southbridges, ISO OUT transfers (such as audio playback through speakers) on the USB OHCI controller may be corrupted when an A-Link express power saving feature is active. PLL power down mode in conjunction with link power management feature L1 being enabled is the bad combination ... this patch prevents them from being enabled when ISO transfers are pending. Signed-off-by: Crane Cai Signed-off-by: Libin Yang Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman --- drivers/usb/host/ohci-hcd.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'drivers/usb/host/ohci-hcd.c') diff --git a/drivers/usb/host/ohci-hcd.c b/drivers/usb/host/ohci-hcd.c index 96fe76e9a6c..89901962cbf 100644 --- a/drivers/usb/host/ohci-hcd.c +++ b/drivers/usb/host/ohci-hcd.c @@ -86,6 +86,21 @@ static void ohci_stop (struct usb_hcd *hcd); static int ohci_restart (struct ohci_hcd *ohci); #endif +#ifdef CONFIG_PCI +static void quirk_amd_pll(int state); +static void amd_iso_dev_put(void); +#else +static inline void quirk_amd_pll(int state) +{ + return; +} +static inline void amd_iso_dev_put(void) +{ + return; +} +#endif + + #include "ohci-hub.c" #include "ohci-dbg.c" #include "ohci-mem.c" @@ -886,6 +901,8 @@ static void ohci_stop (struct usb_hcd *hcd) if (quirk_zfmicro(ohci)) del_timer(&ohci->unlink_watchdog); + if (quirk_amdiso(ohci)) + amd_iso_dev_put(); remove_debug_files (ohci); ohci_mem_cleanup (ohci); -- cgit v1.2.3