[omap35xx]: Re-order patches, add nand sub-page alignment
authorhcg <hcg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Thu, 25 Aug 2011 10:37:30 +0000 (10:37 +0000)
committerhcg <hcg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Thu, 25 Aug 2011 10:37:30 +0000 (10:37 +0000)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@28084 3c298f89-4303-0410-b956-a3cf2f4a3e73

target/linux/omap35xx/patches-3.0/001-change_partition_table.patch [new file with mode: 0644]
target/linux/omap35xx/patches-3.0/002-fix_twl_rtc.patch [new file with mode: 0644]
target/linux/omap35xx/patches-3.0/003-change_partition_table.patch [deleted file]
target/linux/omap35xx/patches-3.0/003-nand_subpage_align.patch [new file with mode: 0644]
target/linux/omap35xx/patches-3.0/004-fix-twl-rtc.patch [deleted file]

diff --git a/target/linux/omap35xx/patches-3.0/001-change_partition_table.patch b/target/linux/omap35xx/patches-3.0/001-change_partition_table.patch
new file mode 100644 (file)
index 0000000..65ba45a
--- /dev/null
@@ -0,0 +1,34 @@
+--- linux-2.6.36.1/arch/arm/mach-omap2/board-overo.c.old       2011-02-18 12:24:24.000000000 +0100
++++ linux-2.6.36.1/arch/arm/mach-omap2/board-overo.c   2011-02-18 12:38:40.000000000 +0100
+@@ -250,13 +250,28 @@
+               .size           = 2 * NAND_BLOCK_SIZE,
+       },
+       {
+-              .name           = "linux",
++              .name           = "kernel 0",
+               .offset         = MTDPART_OFS_APPEND,   /* Offset = 0x280000 */
+-              .size           = 32 * NAND_BLOCK_SIZE,
++              .size           = 16 * NAND_BLOCK_SIZE,
+       },
+       {
+-              .name           = "rootfs",
++              .name           = "kernel 1",
++              .offset         = MTDPART_OFS_APPEND,   /* Offset = 0x480000 */
++              .size           = 16 * NAND_BLOCK_SIZE,
++      },
++      {
++              .name           = "rootfs 0",
+               .offset         = MTDPART_OFS_APPEND,   /* Offset = 0x680000 */
++              .size           = 512 * NAND_BLOCK_SIZE,
++      },
++      {
++              .name           = "rootfs 1",
++              .offset         = MTDPART_OFS_APPEND,   /* Offset = 0x2e80000 */
++              .size           = 512 * NAND_BLOCK_SIZE,
++      },
++      {
++              .name           = "data",
++              .offset         = MTDPART_OFS_APPEND,   /* Offset = 0x5680000 */
+               .size           = MTDPART_SIZ_FULL,
+       },
+ };
diff --git a/target/linux/omap35xx/patches-3.0/002-fix_twl_rtc.patch b/target/linux/omap35xx/patches-3.0/002-fix_twl_rtc.patch
new file mode 100644 (file)
index 0000000..ef243ea
--- /dev/null
@@ -0,0 +1,26 @@
+--- a/drivers/rtc/rtc-twl.c
++++ b/drivers/rtc/rtc-twl.c
+@@ -362,14 +362,6 @@ static irqreturn_t twl_rtc_interrupt(int
+       int res;
+       u8 rd_reg;
+-#ifdef CONFIG_LOCKDEP
+-      /* WORKAROUND for lockdep forcing IRQF_DISABLED on us, which
+-       * we don't want and can't tolerate.  Although it might be
+-       * friendlier not to borrow this thread context...
+-       */
+-      local_irq_enable();
+-#endif
+-
+       res = twl_rtc_read_u8(&rd_reg, REG_RTC_STATUS_REG);
+       if (res)
+               goto out;
+@@ -462,7 +454,7 @@ static int __devinit twl_rtc_probe(struc
+       if (ret < 0)
+               goto out1;
+-      ret = request_irq(irq, twl_rtc_interrupt,
++      ret = request_threaded_irq(irq, NULL, twl_rtc_interrupt,
+                               IRQF_TRIGGER_RISING,
+                               dev_name(&rtc->dev), rtc);
+       if (ret < 0) {
diff --git a/target/linux/omap35xx/patches-3.0/003-change_partition_table.patch b/target/linux/omap35xx/patches-3.0/003-change_partition_table.patch
deleted file mode 100644 (file)
index 65ba45a..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
---- linux-2.6.36.1/arch/arm/mach-omap2/board-overo.c.old       2011-02-18 12:24:24.000000000 +0100
-+++ linux-2.6.36.1/arch/arm/mach-omap2/board-overo.c   2011-02-18 12:38:40.000000000 +0100
-@@ -250,13 +250,28 @@
-               .size           = 2 * NAND_BLOCK_SIZE,
-       },
-       {
--              .name           = "linux",
-+              .name           = "kernel 0",
-               .offset         = MTDPART_OFS_APPEND,   /* Offset = 0x280000 */
--              .size           = 32 * NAND_BLOCK_SIZE,
-+              .size           = 16 * NAND_BLOCK_SIZE,
-       },
-       {
--              .name           = "rootfs",
-+              .name           = "kernel 1",
-+              .offset         = MTDPART_OFS_APPEND,   /* Offset = 0x480000 */
-+              .size           = 16 * NAND_BLOCK_SIZE,
-+      },
-+      {
-+              .name           = "rootfs 0",
-               .offset         = MTDPART_OFS_APPEND,   /* Offset = 0x680000 */
-+              .size           = 512 * NAND_BLOCK_SIZE,
-+      },
-+      {
-+              .name           = "rootfs 1",
-+              .offset         = MTDPART_OFS_APPEND,   /* Offset = 0x2e80000 */
-+              .size           = 512 * NAND_BLOCK_SIZE,
-+      },
-+      {
-+              .name           = "data",
-+              .offset         = MTDPART_OFS_APPEND,   /* Offset = 0x5680000 */
-               .size           = MTDPART_SIZ_FULL,
-       },
- };
diff --git a/target/linux/omap35xx/patches-3.0/003-nand_subpage_align.patch b/target/linux/omap35xx/patches-3.0/003-nand_subpage_align.patch
new file mode 100644 (file)
index 0000000..4bb854d
--- /dev/null
@@ -0,0 +1,22 @@
+diff -urN linux-2.6.38.old/drivers/mtd/nand/omap2.c linux-2.6.38/drivers/mtd/nand/omap2.c
+--- linux-2.6.38.old/drivers/mtd/nand/omap2.c  2011-03-15 02:20:32.000000000 +0100
++++ linux-2.6.38/drivers/mtd/nand/omap2.c      2011-03-21 15:05:21.000000000 +0100
+@@ -245,6 +245,18 @@
+       int ret = 0;
+       u32 *p = (u32 *)buf;
++      /* u32 align the buffer and read */
++      /* NB: This assumes the buf ptr can be aligned *down* which is a valid.
++      * Assumption when dealing with ecc buffers etc.
++      */
++      u32 addr = (u32)p;
++
++      int diff = addr & 3;
++      addr -= diff;
++      len += diff;
++      len = (len + 3) & ~3;
++      p = (u32 *)addr;
++
+       /* take care of subpage reads */
+       if (len % 4) {
+               if (info->nand.options & NAND_BUSWIDTH_16)
diff --git a/target/linux/omap35xx/patches-3.0/004-fix-twl-rtc.patch b/target/linux/omap35xx/patches-3.0/004-fix-twl-rtc.patch
deleted file mode 100644 (file)
index ef243ea..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
---- a/drivers/rtc/rtc-twl.c
-+++ b/drivers/rtc/rtc-twl.c
-@@ -362,14 +362,6 @@ static irqreturn_t twl_rtc_interrupt(int
-       int res;
-       u8 rd_reg;
--#ifdef CONFIG_LOCKDEP
--      /* WORKAROUND for lockdep forcing IRQF_DISABLED on us, which
--       * we don't want and can't tolerate.  Although it might be
--       * friendlier not to borrow this thread context...
--       */
--      local_irq_enable();
--#endif
--
-       res = twl_rtc_read_u8(&rd_reg, REG_RTC_STATUS_REG);
-       if (res)
-               goto out;
-@@ -462,7 +454,7 @@ static int __devinit twl_rtc_probe(struc
-       if (ret < 0)
-               goto out1;
--      ret = request_irq(irq, twl_rtc_interrupt,
-+      ret = request_threaded_irq(irq, NULL, twl_rtc_interrupt,
-                               IRQF_TRIGGER_RISING,
-                               dev_name(&rtc->dev), rtc);
-       if (ret < 0) {
This page took 0.032534 seconds and 4 git commands to generate.