brcm63xx: Add fallback sprom for AR-5387un

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
Signed-off-by: Jonas Gorski <jogo@openwrt.org>

SVN-Revision: 42103
This commit is contained in:
Jonas Gorski 2014-08-10 12:21:55 +00:00
parent d1f731866b
commit 23df30ca4a
25 changed files with 92 additions and 56 deletions

View file

@ -1,15 +1,43 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -168,6 +168,79 @@ static struct board_info __initdata boar
@@ -168,6 +168,115 @@ static struct board_info __initdata boar
},
};
+static struct sprom_fixup __initdata ar5387un_fixups[] = {
+ { .offset = 2, .value = 0x05bb },
+ { .offset = 65, .value = 0x1204 },
+ { .offset = 78, .value = 0x0303 },
+ { .offset = 79, .value = 0x0202 },
+ { .offset = 80, .value = 0xff02 },
+ { .offset = 87, .value = 0x0315 },
+ { .offset = 88, .value = 0x0315 },
+ { .offset = 96, .value = 0x2048 },
+ { .offset = 97, .value = 0xff11 },
+ { .offset = 98, .value = 0x1567 },
+ { .offset = 99, .value = 0xfb24 },
+ { .offset = 100, .value = 0x3e3c },
+ { .offset = 101, .value = 0x4038 },
+ { .offset = 102, .value = 0xfe7f },
+ { .offset = 103, .value = 0x1279 },
+ { .offset = 112, .value = 0x2048 },
+ { .offset = 113, .value = 0xff03 },
+ { .offset = 114, .value = 0x154c },
+ { .offset = 115, .value = 0xfb27 },
+ { .offset = 116, .value = 0x3e3c },
+ { .offset = 117, .value = 0x4038 },
+ { .offset = 118, .value = 0xfe87 },
+ { .offset = 119, .value = 0x1233 },
+ { .offset = 203, .value = 0x2226 },
+};
+
+static struct board_info __initdata board_AR5387un = {
+ .name = "96328A-1441N1",
+ .expected_cpu_id = 0x6328,
+
+ .has_uart0 = 1,
+ .has_pci = 1,
+ .use_fallback_sprom = 1,
+ .has_ohci0 = 1,
+ .has_ehci0 = 1,
+ .num_usbh_ports = 1,
@ -75,12 +103,20 @@
+ .debounce_interval = BCM963XX_KEYS_DEBOUNCE_INTERVAL,
+ },
+ },
+
+ .fallback_sprom = {
+ .type = SPROM_BCM43225,
+ .pci_bus = 1,
+ .pci_dev = 0,
+ .board_fixups = ar5387un_fixups,
+ .num_board_fixups = ARRAY_SIZE(ar5387un_fixups),
+ },
+};
+
static struct board_info __initdata board_963281TAN = {
.name = "963281TAN",
.expected_cpu_id = 0x6328,
@@ -3129,6 +3202,7 @@ static const struct board_info __initcon
@@ -3129,6 +3238,7 @@ static const struct board_info __initcon
#endif
#ifdef CONFIG_BCM63XX_CPU_6328
&board_96328avng,

View file

@ -1,7 +1,7 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -168,6 +168,73 @@ static struct board_info __initdata boar
},
@@ -195,6 +195,73 @@ static struct sprom_fixup __initdata ar5
{ .offset = 203, .value = 0x2226 },
};
+static struct board_info __initdata board_AR5381u = {
@ -74,7 +74,7 @@
static struct board_info __initdata board_AR5387un = {
.name = "96328A-1441N1",
.expected_cpu_id = 0x6328,
@@ -3202,6 +3269,7 @@ static const struct board_info __initcon
@@ -3238,6 +3305,7 @@ static const struct board_info __initcon
#endif
#ifdef CONFIG_BCM63XX_CPU_6328
&board_96328avng,

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -931,6 +931,55 @@ static struct board_info __initdata boar
@@ -967,6 +967,55 @@ static struct board_info __initdata boar
.has_uart0 = 1,
};
@ -56,7 +56,7 @@
#endif
/*
@@ -3283,6 +3332,7 @@ static const struct board_info __initcon
@@ -3319,6 +3368,7 @@ static const struct board_info __initcon
#endif
#ifdef CONFIG_BCM63XX_CPU_6345
&board_96345gw2,

View file

@ -8,7 +8,7 @@
#include <linux/platform_device.h>
#include <linux/spi/spi.h>
#include <linux/spi/spi_gpio.h>
@@ -1835,6 +1836,492 @@ static struct board_info __initdata boar
@@ -1871,6 +1872,492 @@ static struct board_info __initdata boar
},
};
@ -501,7 +501,7 @@
/* T-Home Speedport W 303V Typ B */
static struct board_info __initdata board_spw303v = {
.name = "96358-502V",
@@ -3371,6 +3858,10 @@ static const struct board_info __initcon
@@ -3407,6 +3894,10 @@ static const struct board_info __initcon
&board_nb4_fxc_r2,
&board_ct6373_1,
&board_HW553,
@ -512,7 +512,7 @@
&board_spw303v,
&board_DVAG3810BN,
#endif
@@ -3390,13 +3881,37 @@ static void __init boardid_fixup(u8 *boo
@@ -3426,13 +3917,37 @@ static void __init boardid_fixup(u8 *boo
struct bcm_tag *tag = (struct bcm_tag *)(boot_addr + CFE_OFFSET_64K);
char *board_name = (char *)bcm63xx_nvram_get_name();

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -981,6 +981,60 @@ static struct board_info __initdata boar
@@ -1017,6 +1017,60 @@ static struct board_info __initdata boar
},
},
};
@ -61,7 +61,7 @@
#endif
/*
@@ -3820,6 +3874,7 @@ static const struct board_info __initcon
@@ -3856,6 +3910,7 @@ static const struct board_info __initcon
#ifdef CONFIG_BCM63XX_CPU_6345
&board_96345gw2,
&board_rta770bw,

View file

@ -12,7 +12,7 @@ Signed-off-by: Marcin Jurkowski <marcin1j@gmail.com>
---
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -1643,6 +1643,122 @@ static struct board_info __initdata boar
@@ -1679,6 +1679,122 @@ static struct board_info __initdata boar
},
};
@ -135,7 +135,7 @@ Signed-off-by: Marcin Jurkowski <marcin1j@gmail.com>
static struct board_info __initdata board_rta1025w_16 = {
.name = "RTA1025W_16",
.expected_cpu_id = 0x6348,
@@ -3864,6 +3980,7 @@ static const struct board_info __initcon
@@ -3900,6 +4016,7 @@ static const struct board_info __initcon
&board_963281TAN,
&board_A4001N1,
&board_dsl_274xb_f1,

View file

@ -6,7 +6,7 @@ Signed-off-by: Max Staudt <openwrt.max@enpas.org>
---
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -3819,6 +3819,96 @@ static struct board_info __initdata boar
@@ -3855,6 +3855,96 @@ static struct board_info __initdata boar
.devs = nb6_devices,
.num_devs = ARRAY_SIZE(nb6_devices),
};
@ -103,7 +103,7 @@ Signed-off-by: Max Staudt <openwrt.max@enpas.org>
#endif
/*
@@ -4040,6 +4130,7 @@ static const struct board_info __initcon
@@ -4076,6 +4166,7 @@ static const struct board_info __initcon
#ifdef CONFIG_BCM63XX_CPU_6362
&board_nb6,

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -2846,6 +2846,99 @@ static struct board_info __initdata boar
@@ -2882,6 +2882,99 @@ static struct board_info __initdata boar
.has_ohci0 = 1,
.has_ehci0 = 1,

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -1821,6 +1821,19 @@ static struct board_info __initdata boar
@@ -1857,6 +1857,19 @@ static struct board_info __initdata boar
},
.has_ohci0 = 1,

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -1145,6 +1145,17 @@ static struct board_info __initdata boar
@@ -1181,6 +1181,17 @@ static struct board_info __initdata boar
.active_low = 1,
},
},

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -623,6 +623,8 @@ static struct board_info __initdata boar
@@ -659,6 +659,8 @@ static struct board_info __initdata boar
.has_uart0 = 1,
.has_enet0 = 1,
.enet0 = {
@ -9,7 +9,7 @@
.force_speed_100 = 1,
.force_duplex_full = 1,
},
@@ -666,6 +668,8 @@ static struct board_info __initdata boar
@@ -702,6 +704,8 @@ static struct board_info __initdata boar
.has_uart0 = 1,
.has_enet0 = 1,
.enet0 = {
@ -18,7 +18,7 @@
.force_speed_100 = 1,
.force_duplex_full = 1,
},
@@ -1101,6 +1105,8 @@ static struct board_info __initdata boar
@@ -1137,6 +1141,8 @@ static struct board_info __initdata boar
.use_internal_phy = 1,
},
.enet1 = {
@ -27,7 +27,7 @@
.force_speed_100 = 1,
.force_duplex_full = 1,
},
@@ -1174,6 +1180,8 @@ static struct board_info __initdata boar
@@ -1210,6 +1216,8 @@ static struct board_info __initdata boar
},
.enet1 = {
@ -36,7 +36,7 @@
.force_speed_100 = 1,
.force_duplex_full = 1,
},
@@ -1418,6 +1426,8 @@ static struct board_info __initdata boar
@@ -1454,6 +1462,8 @@ static struct board_info __initdata boar
.use_internal_phy = 1,
},
.enet1 = {
@ -45,7 +45,7 @@
.force_speed_100 = 1,
.force_duplex_full = 1,
},
@@ -1594,6 +1604,8 @@ static struct board_info __initdata boar
@@ -1630,6 +1640,8 @@ static struct board_info __initdata boar
},
.enet1 = {
@ -54,7 +54,7 @@
.force_speed_100 = 1,
.force_duplex_full = 1,
},
@@ -1785,6 +1797,8 @@ static struct board_info __initdata boar
@@ -1821,6 +1833,8 @@ static struct board_info __initdata boar
.use_internal_phy = 1,
},
.enet1 = {
@ -63,7 +63,7 @@
.force_speed_100 = 1,
.force_duplex_full = 1,
},
@@ -1807,6 +1821,8 @@ static struct board_info __initdata boar
@@ -1843,6 +1857,8 @@ static struct board_info __initdata boar
.use_internal_phy = 1,
},
.enet1 = {
@ -72,7 +72,7 @@
.force_speed_100 = 1,
.force_duplex_full = 1,
},
@@ -1827,6 +1843,8 @@ static struct board_info __initdata boar
@@ -1863,6 +1879,8 @@ static struct board_info __initdata boar
.use_internal_phy = 1,
},
.enet1 = {
@ -81,7 +81,7 @@
.force_speed_100 = 1,
.force_duplex_full = 1,
},
@@ -2670,6 +2688,8 @@ static struct board_info __initdata boar
@@ -2706,6 +2724,8 @@ static struct board_info __initdata boar
},
.enet1 = {
@ -90,7 +90,7 @@
.force_speed_100 = 1,
.force_duplex_full = 1,
},
@@ -2723,6 +2743,8 @@ static struct board_info __initdata boar
@@ -2759,6 +2779,8 @@ static struct board_info __initdata boar
},
.enet1 = {
@ -99,7 +99,7 @@
.force_speed_100 = 1,
.force_duplex_full = 1,
},
@@ -2864,6 +2886,8 @@ static struct board_info __initdata boar
@@ -2900,6 +2922,8 @@ static struct board_info __initdata boar
},
.enet1 = {
@ -108,7 +108,7 @@
.force_speed_100 = 1,
.force_duplex_full = 1,
},
@@ -2982,6 +3006,8 @@ static struct board_info __initdata boar
@@ -3018,6 +3042,8 @@ static struct board_info __initdata boar
},
.enet1 = {

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -3014,6 +3014,94 @@ static struct board_info __initdata boar
@@ -3050,6 +3050,94 @@ static struct board_info __initdata boar
.has_ohci0 = 1,
.has_ehci0 = 1,

View file

@ -94,7 +94,7 @@
* known 6328 boards
*/
#ifdef CONFIG_BCM63XX_CPU_6328
@@ -4294,6 +4381,9 @@ static const struct board_info __initcon
@@ -4330,6 +4417,9 @@ static const struct board_info __initcon
#ifdef CONFIG_BCM63XX_CPU_3368
&board_cvg834g,
#endif

View file

@ -95,7 +95,7 @@
#endif
/*
@@ -4383,6 +4471,7 @@ static const struct board_info __initcon
@@ -4419,6 +4507,7 @@ static const struct board_info __initcon
#endif
#ifdef CONFIG_BCM63XX_CPU_6318
&board_96318ref,

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -4463,6 +4463,75 @@ static struct board_info __initdata boar
@@ -4499,6 +4499,75 @@ static struct board_info __initdata boar
#endif
/*
@ -76,7 +76,7 @@
* all boards
*/
static const struct board_info __initconst *bcm963xx_boards[] = {
@@ -4547,6 +4616,9 @@ static const struct board_info __initcon
@@ -4583,6 +4652,9 @@ static const struct board_info __initcon
&board_96368mvwg,
&board_96368mvngr,
#endif

View file

@ -8,7 +8,7 @@ Signed-off-by: Adrian Feliks <mexit@o2.pl>
---
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -1099,6 +1099,51 @@ static struct board_info __initdata boar
@@ -1135,6 +1135,51 @@ static struct board_info __initdata boar
},
};
@ -60,7 +60,7 @@ Signed-off-by: Adrian Feliks <mexit@o2.pl>
#endif
/*
@@ -4583,6 +4628,7 @@ static const struct board_info __initcon
@@ -4619,6 +4664,7 @@ static const struct board_info __initcon
&board_96348A_122,
&board_CPVA502plus,
&board_96348W3,

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -4574,6 +4574,108 @@ static struct board_info __initdata boar
@@ -4610,6 +4610,108 @@ static struct board_info __initdata boar
},
},
};
@ -109,7 +109,7 @@
#endif
/*
@@ -4664,6 +4766,7 @@ static const struct board_info __initcon
@@ -4700,6 +4802,7 @@ static const struct board_info __initcon
#endif
#ifdef CONFIG_BCM63XX_CPU_63268
&board_963269bhr,

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -4511,6 +4511,131 @@ static struct board_info __initdata boar
@@ -4547,6 +4547,131 @@ static struct board_info __initdata boar
* known 63268/63269 boards
*/
#ifdef CONFIG_BCM63XX_CPU_63268
@ -132,7 +132,7 @@
static struct board_info __initdata board_963269bhr = {
.name = "963269BHR",
.expected_cpu_id = 0x63268,
@@ -4765,6 +4890,7 @@ static const struct board_info __initcon
@@ -4801,6 +4926,7 @@ static const struct board_info __initcon
&board_96368mvngr,
#endif
#ifdef CONFIG_BCM63XX_CPU_63268

View file

@ -8,7 +8,7 @@
#include <linux/platform_device.h>
#include <linux/spi/spi.h>
#include <linux/spi/spi_gpio.h>
@@ -4505,6 +4506,99 @@ static struct board_info __initdata boar
@@ -4541,6 +4542,99 @@ static struct board_info __initdata boar
.has_ohci0 = 1,
.has_ehci0 = 1,
};
@ -108,7 +108,7 @@
#endif
/*
@@ -4888,6 +4982,7 @@ static const struct board_info __initcon
@@ -4924,6 +5018,7 @@ static const struct board_info __initcon
#ifdef CONFIG_BCM63XX_CPU_6368
&board_96368mvwg,
&board_96368mvngr,

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -4507,6 +4507,98 @@ static struct board_info __initdata boar
@@ -4543,6 +4543,98 @@ static struct board_info __initdata boar
.has_ehci0 = 1,
};
@ -99,7 +99,7 @@
static struct b53_platform_data WAP5813n_b53_pdata = {
.alias = "eth0",
};
@@ -4982,6 +5074,7 @@ static const struct board_info __initcon
@@ -5018,6 +5110,7 @@ static const struct board_info __initcon
#ifdef CONFIG_BCM63XX_CPU_6368
&board_96368mvwg,
&board_96368mvngr,

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -4599,6 +4599,98 @@ static struct board_info __initdata boar
@@ -4635,6 +4635,98 @@ static struct board_info __initdata boar
},
};
@ -99,7 +99,7 @@
static struct b53_platform_data WAP5813n_b53_pdata = {
.alias = "eth0",
};
@@ -5075,6 +5167,7 @@ static const struct board_info __initcon
@@ -5111,6 +5203,7 @@ static const struct board_info __initcon
&board_96368mvwg,
&board_96368mvngr,
&board_VR3025u,

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -4507,6 +4507,89 @@ static struct board_info __initdata boar
@@ -4543,6 +4543,89 @@ static struct board_info __initdata boar
.has_ehci0 = 1,
};
@ -90,7 +90,7 @@
static struct board_info __initdata board_VR3025u = {
.name = "96368M-1541N",
.expected_cpu_id = 0x6368,
@@ -5166,6 +5249,7 @@ static const struct board_info __initcon
@@ -5202,6 +5285,7 @@ static const struct board_info __initcon
#ifdef CONFIG_BCM63XX_CPU_6368
&board_96368mvwg,
&board_96368mvngr,

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -4097,6 +4097,49 @@ static struct board_info __initdata boar
@@ -4133,6 +4133,49 @@ static struct board_info __initdata boar
.num_spis = ARRAY_SIZE(ct6373_spi_devices),
};
@ -50,7 +50,7 @@
static struct board_info __initdata board_HW553 = {
.name = "HW553",
.expected_cpu_id = 0x6358,
@@ -5232,6 +5275,7 @@ static const struct board_info __initcon
@@ -5268,6 +5311,7 @@ static const struct board_info __initcon
&board_nb4_fxc_r1,
&board_nb4_fxc_r2,
&board_ct6373_1,

View file

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -555,6 +555,88 @@ static struct board_info __initdata boar
@@ -591,6 +591,88 @@ static struct board_info __initdata boar
},
};
@ -89,7 +89,7 @@
static struct board_info __initdata board_A4001N1 = {
.name = "963281T_TEF",
.expected_cpu_id = 0x6328,
@@ -5223,6 +5305,7 @@ static const struct board_info __initcon
@@ -5259,6 +5341,7 @@ static const struct board_info __initcon
&board_AR5381u,
&board_AR5387un,
&board_963281TAN,

View file

@ -142,7 +142,7 @@
#endif
/*
@@ -5299,6 +5434,7 @@ static const struct board_info __initcon
@@ -5335,6 +5470,7 @@ static const struct board_info __initcon
#ifdef CONFIG_BCM63XX_CPU_6318
&board_96318ref,
&board_96318ref_p300,