aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ps3/patches-2.6.28/0012-mtd-ps3vram-Use-msleep-in-waits.patch
diff options
context:
space:
mode:
authorGeoff Levand <geoff@infradead.org>2009-08-26 22:00:33 +0000
committerGeoff Levand <geoff@infradead.org>2009-08-26 22:00:33 +0000
commitb552a51b7c9c490b84cd3e28c2da82e1794f1fec (patch)
tree31b84762cbecdc42e37591cd69e69ab146abc893 /target/linux/ps3/patches-2.6.28/0012-mtd-ps3vram-Use-msleep-in-waits.patch
parente6b0215078ab91df0ad56143d332c1536919bb6c (diff)
downloadmaster-187ad058-b552a51b7c9c490b84cd3e28c2da82e1794f1fec.tar.gz
master-187ad058-b552a51b7c9c490b84cd3e28c2da82e1794f1fec.tar.bz2
master-187ad058-b552a51b7c9c490b84cd3e28c2da82e1794f1fec.zip
ps3: Remove support for linux-2.6.28
Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@17412 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/ps3/patches-2.6.28/0012-mtd-ps3vram-Use-msleep-in-waits.patch')
-rw-r--r--target/linux/ps3/patches-2.6.28/0012-mtd-ps3vram-Use-msleep-in-waits.patch87
1 files changed, 0 insertions, 87 deletions
diff --git a/target/linux/ps3/patches-2.6.28/0012-mtd-ps3vram-Use-msleep-in-waits.patch b/target/linux/ps3/patches-2.6.28/0012-mtd-ps3vram-Use-msleep-in-waits.patch
deleted file mode 100644
index 0f235094c0..0000000000
--- a/target/linux/ps3/patches-2.6.28/0012-mtd-ps3vram-Use-msleep-in-waits.patch
+++ /dev/null
@@ -1,87 +0,0 @@
-From 60c0c5987b0996a7c7c4c6d90f63ed413c368a71 Mon Sep 17 00:00:00 2001
-From: Geoff Levand <geoffrey.levand@am.sony.com>
-Date: Wed, 7 Jan 2009 17:22:02 -0800
-Subject: [PATCH] mtd/ps3vram: Use msleep in waits
-
-Replace the use of udelay() with msleep() in the looping wait routines
-ps3vram_notifier_wait() and ps3vram_wait_ring().
-
-Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com>
-Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
----
- drivers/mtd/devices/ps3vram.c | 42 +++++++++++++++++-----------------------
- 1 files changed, 18 insertions(+), 24 deletions(-)
-
-diff --git a/drivers/mtd/devices/ps3vram.c b/drivers/mtd/devices/ps3vram.c
-index 91cc2af..d592414 100644
---- a/drivers/mtd/devices/ps3vram.c
-+++ b/drivers/mtd/devices/ps3vram.c
-@@ -109,22 +109,19 @@ static void ps3vram_notifier_reset(struct mtd_info *mtd)
- notify[i] = 0xffffffff;
- }
-
--static int ps3vram_notifier_wait(struct mtd_info *mtd, int timeout_ms)
-+static int ps3vram_notifier_wait(struct mtd_info *mtd, unsigned int timeout_ms)
- {
- struct ps3vram_priv *priv = mtd->priv;
- u32 *notify = ps3vram_get_notifier(priv->reports, NOTIFIER);
--
-- timeout_ms *= 1000;
-+ unsigned long timeout = jiffies + msecs_to_jiffies(timeout_ms);
-
- do {
-- if (notify[3] == 0)
-+ if (!notify[3])
- return 0;
-+ msleep(1);
-+ } while (time_before(jiffies, timeout));
-
-- if (timeout_ms)
-- udelay(1);
-- } while (timeout_ms--);
--
-- return -1;
-+ return -ETIMEDOUT;
- }
-
- static void ps3vram_init_ring(struct mtd_info *mtd)
-@@ -135,25 +132,22 @@ static void ps3vram_init_ring(struct mtd_info *mtd)
- priv->ctrl[CTRL_GET] = FIFO_BASE + FIFO_OFFSET;
- }
-
--static int ps3vram_wait_ring(struct mtd_info *mtd, int timeout)
-+static int ps3vram_wait_ring(struct mtd_info *mtd, unsigned int timeout_ms)
- {
- struct ps3vram_priv *priv = mtd->priv;
-+ unsigned long timeout = jiffies + msecs_to_jiffies(timeout_ms);
-
-- /* wait until setup commands are processed */
-- timeout *= 1000;
-- while (--timeout) {
-+ do {
- if (priv->ctrl[CTRL_PUT] == priv->ctrl[CTRL_GET])
-- break;
-- udelay(1);
-- }
-- if (timeout == 0) {
-- dev_dbg(priv->dev, "%s:%d: FIFO timeout (%08x/%08x/%08x)\n",
-- __func__, __LINE__, priv->ctrl[CTRL_PUT],
-- priv->ctrl[CTRL_GET], priv->ctrl[CTRL_TOP]);
-- return -ETIMEDOUT;
-- }
-+ return 0;
-+ msleep(1);
-+ } while (time_before(jiffies, timeout));
-
-- return 0;
-+ dev_dbg(priv->dev, "%s:%d: FIFO timeout (%08x/%08x/%08x)\n", __func__,
-+ __LINE__, priv->ctrl[CTRL_PUT], priv->ctrl[CTRL_GET],
-+ priv->ctrl[CTRL_TOP]);
-+
-+ return -ETIMEDOUT;
- }
-
- static void ps3vram_out_ring(struct ps3vram_priv *priv, u32 data)
---
-1.6.0.4
-