summaryrefslogtreecommitdiffstats
path: root/target
diff options
context:
space:
mode:
authorRoman Yeryomin <roman@advem.lv>2013-05-18 12:50:22 +0300
committerRoman Yeryomin <roman@advem.lv>2013-05-18 12:50:22 +0300
commit63ba5d38377a1b1b7734972602f35b6c36df3f7e (patch)
treeb5d9d86ea6784ea25322fb0f544e6432eb3756a5 /target
parente6d87036412b952cb083eff2dc716aee97a771f2 (diff)
fix flash partiotions
Signed-off-by: Roman Yeryomin <roman@advem.lv>
Diffstat (limited to 'target')
-rw-r--r--target/linux/realtek/patches-2.6.30/9991-drivers-mtd-maps-openwrt.patch81
1 files changed, 81 insertions, 0 deletions
diff --git a/target/linux/realtek/patches-2.6.30/9991-drivers-mtd-maps-openwrt.patch b/target/linux/realtek/patches-2.6.30/9991-drivers-mtd-maps-openwrt.patch
new file mode 100644
index 000000000..fe413d990
--- /dev/null
+++ b/target/linux/realtek/patches-2.6.30/9991-drivers-mtd-maps-openwrt.patch
@@ -0,0 +1,81 @@
+--- files/drivers/mtd/maps/rtl819x_flash.c 2013-05-10 23:08:00.000000000 +0300
++++ files.old/drivers/mtd/maps/rtl819x_flash.c 2013-05-10 15:34:50.000000000 +0300
+@@ -164,45 +164,39 @@
+ },
+ };
+
+-#elif defined( CONFIG_ROOTFS_SQUASH )
+-#ifndef CONFIG_RTL_FLASH_DUAL_IMAGE_ENABLE
+-static struct mtd_partition rtl8196_parts1[] = {
+- {
+- name: "boot+cfg+linux",
+- size: (CONFIG_RTL_ROOT_IMAGE_OFFSET-0),
+- offset: 0x00000000,
+- },
+- {
+- name: "root fs",
+-#ifdef CONFIG_RTL_TWO_SPI_FLASH_ENABLE
+-#ifdef CONFIG_MTD_CONCAT
+- size: (CONFIG_RTL_SPI_FLASH1_SIZE+CONFIG_RTL_SPI_FLASH2_SIZE-CONFIG_RTL_ROOT_IMAGE_OFFSET),
+-#else
+- size: (CONFIG_RTL_SPI_FLASH1_SIZE-CONFIG_RTL_ROOT_IMAGE_OFFSET),
+-#endif
+-#else
+-#if !defined(CONFIG_MTD_CHAR)
+- size: (CONFIG_RTL_FLASH_SIZE-CONFIG_RTL_ROOT_IMAGE_OFFSET),
+-#else
+- size: (CONFIG_RTL_FLATFS_IMAGE_OFFSET-CONFIG_RTL_ROOT_IMAGE_OFFSET),
+-#endif
+-#endif
+- offset: (CONFIG_RTL_ROOT_IMAGE_OFFSET),
+- }
+-#if defined(CONFIG_MTD_CHAR)
+- ,
+- {
+- name: "flatfs",
+-
+- size: (CONFIG_RTL_FLASH_SIZE-CONFIG_RTL_FLATFS_IMAGE_OFFSET),
+- offset: (CONFIG_RTL_FLATFS_IMAGE_OFFSET),
+- }
+-#endif
+-
+-
+-
+-};
+-
++#elif defined( CONFIG_ROOTFS_SQUASH )
++#ifndef CONFIG_RTL_FLASH_DUAL_IMAGE_ENABLE
++static struct mtd_partition rtl8196_parts1[] = {
++ {
++ name: "boot+cfg",
++ size: (CONFIG_RTL_LINUX_IMAGE_OFFSET - 0),
++ offset: 0x00000000,
++ },
++ {
++ name: "kernel",
++ size: (CONFIG_RTL_ROOT_IMAGE_OFFSET - CONFIG_RTL_LINUX_IMAGE_OFFSET),
++ offset: CONFIG_RTL_LINUX_IMAGE_OFFSET,
++ },
++ {
++ name: "rootfs",
++#ifdef CONFIG_RTL_TWO_SPI_FLASH_ENABLE
++#ifdef CONFIG_MTD_CONCAT
++ size: (CONFIG_RTL_SPI_FLASH1_SIZE + CONFIG_RTL_SPI_FLASH2_SIZE - CONFIG_RTL_ROOT_IMAGE_OFFSET),
++#else
++ size: (CONFIG_RTL_SPI_FLASH1_SIZE - CONFIG_RTL_ROOT_IMAGE_OFFSET),
++#endif
++#else
++ size: (CONFIG_RTL_FLASH_SIZE - CONFIG_RTL_ROOT_IMAGE_OFFSET),
++#endif
++ offset: CONFIG_RTL_ROOT_IMAGE_OFFSET,
++ },
++ {
++ name: "firmware",
++ size: (CONFIG_RTL_FLASH_SIZE - CONFIG_RTL_LINUX_IMAGE_OFFSET),
++ offset: CONFIG_RTL_LINUX_IMAGE_OFFSET,
++ },
++};
++
+ #else //!CONFIG_RTL_FLASH_DUAL_IMAGE_ENABLE
+ static struct mtd_partition rtl8196_parts1[] = {
+ {