summaryrefslogtreecommitdiff
path: root/drivers/usb/host/ehci-hcd.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2012-02-27 10:52:47 +0000
committerAlbert ARIBAUD <albert.u.boot@aribaud.net>2012-03-29 08:12:48 +0200
commit9ab4ce223c1d991e92e15c9aa0f522d61072155d (patch)
tree8a43e077026f24e4a143a04446c48b216d239d92 /drivers/usb/host/ehci-hcd.c
parent1920172ec80b709d017608b6a1d40b766e84c731 (diff)
downloadu-boot-imx-9ab4ce223c1d991e92e15c9aa0f522d61072155d.zip
u-boot-imx-9ab4ce223c1d991e92e15c9aa0f522d61072155d.tar.gz
u-boot-imx-9ab4ce223c1d991e92e15c9aa0f522d61072155d.tar.bz2
usb: Add support for txfifo threshold
CONFIG_USB_EHCI_TXFIFO_THRESH enables setting of the txfilltuning field in the EHCI controller on reset. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Remy Bohmer <linux@bohmer.net> Signed-off-by: Tom Warren <twarren@nvidia.com>
Diffstat (limited to 'drivers/usb/host/ehci-hcd.c')
-rw-r--r--drivers/usb/host/ehci-hcd.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/usb/host/ehci-hcd.c b/drivers/usb/host/ehci-hcd.c
index ef5afc2..b6422d7 100644
--- a/drivers/usb/host/ehci-hcd.c
+++ b/drivers/usb/host/ehci-hcd.c
@@ -255,6 +255,13 @@ static int ehci_reset(void)
#endif
ehci_writel(reg_ptr, tmp);
}
+
+#ifdef CONFIG_USB_EHCI_TXFIFO_THRESH
+ cmd = ehci_readl(&hcor->or_txfilltuning);
+ cmd &= ~TXFIFO_THRESH(0x3f);
+ cmd |= TXFIFO_THRESH(CONFIG_USB_EHCI_TXFIFO_THRESH);
+ ehci_writel(&hcor->or_txfilltuning, cmd);
+#endif
out:
return ret;
}