summaryrefslogtreecommitdiff
path: root/target/linux/brcm63xx/patches-3.3/511-board_V2500V.patch
diff options
context:
space:
mode:
authorjogo <jogo@3c298f89-4303-0410-b956-a3cf2f4a3e73>2012-05-27 13:22:25 +0000
committerjogo <jogo@3c298f89-4303-0410-b956-a3cf2f4a3e73>2012-05-27 13:22:25 +0000
commitc9204063aaf5e8a6020b1105bf0c4dbfd2680c5c (patch)
tree97b902da5264f12b623808ded78c4adc6480d33d /target/linux/brcm63xx/patches-3.3/511-board_V2500V.patch
parentfdbaed3349c2e9c9cea97704c874b10bce4f1fbb (diff)
bcm63xx: add flash type detection
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@31877 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/brcm63xx/patches-3.3/511-board_V2500V.patch')
-rw-r--r--target/linux/brcm63xx/patches-3.3/511-board_V2500V.patch38
1 files changed, 24 insertions, 14 deletions
diff --git a/target/linux/brcm63xx/patches-3.3/511-board_V2500V.patch b/target/linux/brcm63xx/patches-3.3/511-board_V2500V.patch
index da8b0038b7..894ac37961 100644
--- a/target/linux/brcm63xx/patches-3.3/511-board_V2500V.patch
+++ b/target/linux/brcm63xx/patches-3.3/511-board_V2500V.patch
@@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -321,6 +321,63 @@ static struct board_info __initdata boar
+@@ -319,6 +319,63 @@ static struct board_info __initdata boar
},
};
@@ -64,7 +64,7 @@
#endif
/*
-@@ -1787,6 +1844,7 @@ static const struct board_info __initdat
+@@ -1785,6 +1842,7 @@ static const struct board_info __initdat
&board_96348_D4PW,
&board_spw500v,
&board_96348sv,
@@ -72,7 +72,7 @@
#endif
#ifdef CONFIG_BCM63XX_CPU_6358
-@@ -1940,6 +1998,22 @@ void __init board_prom_init(void)
+@@ -1938,6 +1996,22 @@ void __init board_prom_init(void)
val = bcm_mpi_readl(MPI_CSBASE_REG(0));
val &= MPI_CSBASE_BASE_MASK;
boot_addr = (u8 *)KSEG1ADDR(val);
@@ -95,17 +95,27 @@
/* dump cfe version */
cfe = boot_addr + BCM963XX_CFE_VERSION_OFFSET;
-@@ -2160,6 +2234,13 @@ int __init board_register_devices(void)
- val = bcm_mpi_readl(MPI_CSBASE_REG(0));
- val &= MPI_CSBASE_BASE_MASK;
+--- a/arch/mips/bcm63xx/dev-flash.c
++++ b/arch/mips/bcm63xx/dev-flash.c
+@@ -16,6 +16,7 @@
+ #include <linux/mtd/partitions.h>
+ #include <linux/mtd/physmap.h>
-+ /* BT Voyager 2500V has 8 Meg flash in two 4 Meg banks */
-+ /* Loading from CFE always uses Bank 0 */
-+ if (!strcmp(board.name, "V2500V_BB")) {
-+ printk(KERN_INFO PFX "V2500V: Start in Bank 0\n");
-+ val = val + 0x400000; // Select Bank 0 start address
-+ }
++#include <bcm63xx_board.h>
+ #include <bcm63xx_cpu.h>
+ #include <bcm63xx_dev_flash.h>
+ #include <bcm63xx_regs.h>
+@@ -98,6 +99,13 @@ int __init bcm63xx_flash_register(void)
+ val = bcm_mpi_readl(MPI_CSBASE_REG(0));
+ val &= MPI_CSBASE_BASE_MASK;
+
++ /* BT Voyager 2500V has 8 Meg flash in two 4 Meg banks */
++ /* Loading from CFE always uses Bank 0 */
++ if (!strcmp(board_get_name(), "V2500V_BB")) {
++ pr_info("V2500V: Start in Bank 0\n");
++ val = val + 0x400000; // Select Bank 0 start address
++ }
+
- mtd_resources[0].start = val;
- mtd_resources[0].end = 0x1FFFFFFF;
+ mtd_resources[0].start = val;
+ mtd_resources[0].end = 0x1FFFFFFF;