aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/brcm2708/patches-3.10/0018-Use-ndelay-rather-than-udelay.-Thanks-lb.patch
diff options
context:
space:
mode:
authorFlorian Fainelli <florian@openwrt.org>2014-02-28 20:30:08 +0000
committerFlorian Fainelli <florian@openwrt.org>2014-02-28 20:30:08 +0000
commitbb39b8d99aae1f7eb13a97bd874838da91080de6 (patch)
tree3046f53937c0bc5dc13e2b2ab7b688a1932199bf /target/linux/brcm2708/patches-3.10/0018-Use-ndelay-rather-than-udelay.-Thanks-lb.patch
parentc6c0d09f85c211560a1405441925681cfa25e8b1 (diff)
downloadupstream-bb39b8d99aae1f7eb13a97bd874838da91080de6.tar.gz
upstream-bb39b8d99aae1f7eb13a97bd874838da91080de6.tar.bz2
upstream-bb39b8d99aae1f7eb13a97bd874838da91080de6.zip
brcm2708: update against latest rpi-3.10.y branch
Update our copies of the brcm2708 patches to the latest rpi-3.10-y rebased against linux-3.10.y stable (3.10.32). This should hopefully make it easier for us in the future to leverage the raspberry/rpi-* branches. Signed-off-by: Florian Fainelli <florian@openwrt.org> SVN-Revision: 39770
Diffstat (limited to 'target/linux/brcm2708/patches-3.10/0018-Use-ndelay-rather-than-udelay.-Thanks-lb.patch')
-rw-r--r--target/linux/brcm2708/patches-3.10/0018-Use-ndelay-rather-than-udelay.-Thanks-lb.patch44
1 files changed, 44 insertions, 0 deletions
diff --git a/target/linux/brcm2708/patches-3.10/0018-Use-ndelay-rather-than-udelay.-Thanks-lb.patch b/target/linux/brcm2708/patches-3.10/0018-Use-ndelay-rather-than-udelay.-Thanks-lb.patch
new file mode 100644
index 0000000000..00f04d816e
--- /dev/null
+++ b/target/linux/brcm2708/patches-3.10/0018-Use-ndelay-rather-than-udelay.-Thanks-lb.patch
@@ -0,0 +1,44 @@
+From a56370b5a103f3949c5ed2997a971e1949a15132 Mon Sep 17 00:00:00 2001
+From: popcornmix <popcornmix@gmail.com>
+Date: Fri, 22 Jun 2012 12:57:42 +0100
+Subject: [PATCH 018/174] Use ndelay rather than udelay. Thanks lb
+
+---
+ drivers/mmc/host/sdhci-bcm2708.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+--- a/drivers/mmc/host/sdhci-bcm2708.c
++++ b/drivers/mmc/host/sdhci-bcm2708.c
+@@ -249,14 +249,14 @@ static void sdhci_bcm2708_raw_writel(str
+ if (now == last_write_hpt || now == last_write_hpt+1) {
+ /* we can't guarantee any significant time has
+ * passed - we'll have to wait anyway ! */
+- udelay((ns_2clk+1000-1)/1000);
++ ndelay(ns_2clk);
+ } else
+ {
+ /* we must have waited at least this many ns: */
+ unsigned int ns_wait = HPTIME_CLK_NS *
+ (last_write_hpt - now - 1);
+ if (ns_wait < ns_2clk)
+- udelay((ns_2clk-ns_wait+500)/1000);
++ ndelay(ns_2clk - ns_wait);
+ }
+ last_write_hpt = now;
+ }
+@@ -272,13 +272,13 @@ static void sdhci_bcm2708_raw_writel(str
+ ier &= ~SDHCI_INT_DATA_TIMEOUT;
+ writel(ier, host->ioaddr + SDHCI_SIGNAL_ENABLE);
+ timeout_disabled = true;
+- udelay((ns_2clk+1000-1)/1000);
++ ndelay(ns_2clk);
+ } else if (timeout_disabled) {
+ ier = readl(host->ioaddr + SDHCI_SIGNAL_ENABLE);
+ ier |= SDHCI_INT_DATA_TIMEOUT;
+ writel(ier, host->ioaddr + SDHCI_SIGNAL_ENABLE);
+ timeout_disabled = false;
+- udelay((ns_2clk+1000-1)/1000);
++ ndelay(ns_2clk);
+ }
+ #endif
+ writel(val, host->ioaddr + reg);