#include <board_bcm963xx.h>
#define PFX "board_bcm963xx: "
-@@ -871,6 +872,9 @@ int __init board_register_devices(void)
+@@ -877,6 +878,9 @@ int __init board_register_devices(void)
!board_get_mac_address(board.enet1.mac_addr))
bcm63xx_enet_register(1, &board.enet1);
#include <board_bcm963xx.h>
#define PFX "board_bcm963xx: "
-@@ -872,6 +873,9 @@ int __init board_register_devices(void)
+@@ -878,6 +879,9 @@ int __init board_register_devices(void)
!board_get_mac_address(board.enet1.mac_addr))
bcm63xx_enet_register(1, &board.enet1);
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -810,20 +810,6 @@ void __init board_setup(void)
+@@ -816,20 +816,6 @@ void __init board_setup(void)
panic("unexpected CPU for bcm963xx board");
}
static struct resource mtd_resources[] = {
{
.start = 0, /* filled at runtime */
-@@ -833,12 +819,9 @@ static struct resource mtd_resources[] =
+@@ -839,12 +825,9 @@ static struct resource mtd_resources[] =
};
static struct platform_device mtd_dev = {
};
static struct board_info __initdata board_FAST2404 = {
-@@ -832,12 +854,23 @@ static struct platform_device bcm63xx_gp
+@@ -838,12 +860,23 @@ static struct platform_device bcm63xx_gp
.dev.platform_data = &bcm63xx_led_data,
};
if (board.has_uart0)
bcm63xx_uart_register(0);
-@@ -879,5 +912,16 @@ int __init board_register_devices(void)
+@@ -888,5 +921,16 @@ int __init board_register_devices(void)
platform_device_register(&bcm63xx_gpio_leds);
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -846,6 +846,10 @@ static struct platform_device mtd_dev =
+@@ -852,6 +852,10 @@ static struct platform_device mtd_dev =
.num_resources = ARRAY_SIZE(mtd_resources),
};
static struct gpio_led_platform_data bcm63xx_led_data;
static struct platform_device bcm63xx_gpio_leds = {
-@@ -907,6 +911,8 @@ int __init board_register_devices(void)
+@@ -916,6 +920,8 @@ int __init board_register_devices(void)
platform_device_register(&mtd_dev);
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -875,6 +875,7 @@ int __init board_register_devices(void)
+@@ -881,6 +881,7 @@ int __init board_register_devices(void)
{
u32 val;
int button_count = 0;
if (board.has_uart0)
bcm63xx_uart_register(0);
-@@ -913,7 +914,11 @@ int __init board_register_devices(void)
+@@ -922,7 +923,11 @@ int __init board_register_devices(void)
platform_device_register_simple("GPIODEV", 0, &gpiodev_resource, 1);
};
static struct board_info __initdata board_rta1025w_16 = {
-@@ -903,6 +906,9 @@ int __init board_register_devices(void)
+@@ -909,6 +912,9 @@ int __init board_register_devices(void)
if (board.has_dsp)
bcm63xx_dsp_register(&board.dsp);
+ bcm63xx_udc_register();
+
/* read base address of boot chip select (0) */
- val = bcm_mpi_readl(MPI_CSBASE_REG(0));
- val &= MPI_CSBASE_BASE_MASK;
+ if (BCMCPU_IS_6345())
+ val = 0x1fc00000;
--- /dev/null
+++ b/arch/mips/bcm63xx/dev-usb-udc.c
@@ -0,0 +1,58 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -909,6 +909,9 @@ int __init board_register_devices(void)
+@@ -915,6 +915,9 @@ int __init board_register_devices(void)
if (board.has_udc0)
bcm63xx_udc_register();
+ platform_add_devices(board.devs, board.num_devs);
+
/* read base address of boot chip select (0) */
- val = bcm_mpi_readl(MPI_CSBASE_REG(0));
- val &= MPI_CSBASE_BASE_MASK;
+ if (BCMCPU_IS_6345())
+ val = 0x1fc00000;
--- a/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
+++ b/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
@@ -61,6 +61,10 @@ struct board_info {
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -912,6 +912,9 @@ int __init board_register_devices(void)
+@@ -918,6 +918,9 @@ int __init board_register_devices(void)
if (board.num_devs)
platform_add_devices(board.devs, board.num_devs);
+ spi_register_board_info(board.spis, board.num_spis);
+
/* read base address of boot chip select (0) */
- val = bcm_mpi_readl(MPI_CSBASE_REG(0));
- val &= MPI_CSBASE_BASE_MASK;
+ if (BCMCPU_IS_6345())
+ val = 0x1fc00000;
--- a/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
+++ b/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
@@ -65,6 +65,10 @@ struct board_info {
* known 6338 boards
*/
#ifdef CONFIG_BCM63XX_CPU_6338
-@@ -741,6 +748,7 @@ void __init board_prom_init(void)
+@@ -747,6 +754,7 @@ void __init board_prom_init(void)
/* extract nvram data */
memcpy(&nvram, boot_addr + BCM963XX_NVRAM_OFFSET, sizeof(nvram));
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -812,6 +812,8 @@ void __init board_prom_init(void)
+@@ -818,6 +818,8 @@ void __init board_prom_init(void)
if (BCMCPU_IS_6348())
val |= GPIO_MODE_6348_G3_EXT_MII |
GPIO_MODE_6348_G0_EXT_MII;
bcm_gpio_writel(val, GPIO_MODE_REG);
--- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h
+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h
-@@ -401,6 +401,8 @@
+@@ -402,6 +402,8 @@
#define GPIO_MODE_6358_EXTRA_SPI_SS (1 << 7)
#define GPIO_MODE_6358_SERIAL_LED (1 << 10)
#define GPIO_MODE_6358_UTOPIA (1 << 12)
#define BCM_6358_OHCI0_IRQ (IRQ_INTERNAL_BASE + 5)
--- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h
+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h
-@@ -805,4 +805,116 @@
+@@ -771,4 +771,116 @@
#define DMIPSPLLCFG_N2_SHIFT 29
#define DMIPSPLLCFG_N2_MASK (0x7 << DMIPSPLLCFG_N2_SHIFT)
#include <board_bcm963xx.h>
#define PFX "board_bcm963xx: "
-@@ -925,6 +926,9 @@ int __init board_register_devices(void)
+@@ -931,6 +932,9 @@ int __init board_register_devices(void)
if (board.num_spis)
spi_register_board_info(board.spis, board.num_spis);
+ bcm63xx_spi_register();
+
/* read base address of boot chip select (0) */
- val = bcm_mpi_readl(MPI_CSBASE_REG(0));
- val &= MPI_CSBASE_BASE_MASK;
+ if (BCMCPU_IS_6345())
+ val = 0x1fc00000;
/*
* early init callback, read nvram data from flash and checksum it
*/
-@@ -765,6 +792,11 @@ void __init board_prom_init(void)
+@@ -771,6 +798,11 @@ void __init board_prom_init(void)
return;
}
/*
* Register a sane SPROMv2 to make the on-board
* bcm4318 WLAN work
-@@ -953,6 +1479,9 @@ void __init board_prom_init(void)
+@@ -959,6 +1485,9 @@ void __init board_prom_init(void)
boardid_fixup(boot_addr);
}
#endif
#ifdef CONFIG_BCM63XX_CPU_6358
-@@ -2051,6 +2109,22 @@ void __init board_prom_init(void)
- val = bcm_mpi_readl(MPI_CSBASE_REG(0));
- val &= MPI_CSBASE_BASE_MASK;
+@@ -2057,6 +2115,22 @@ void __init board_prom_init(void)
+ val &= MPI_CSBASE_BASE_MASK;
+ }
boot_addr = (u8 *)KSEG1ADDR(val);
+ printk(KERN_INFO PFX "Boot address 0x%08x\n",(unsigned int)boot_addr);
+
/* dump cfe version */
cfe = boot_addr + BCM963XX_CFE_VERSION_OFFSET;
-@@ -2255,6 +2329,13 @@ int __init board_register_devices(void)
- val = bcm_mpi_readl(MPI_CSBASE_REG(0));
- val &= MPI_CSBASE_BASE_MASK;
-
+@@ -2264,6 +2338,14 @@ int __init board_register_devices(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.name, "V2500V_BB")) {
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -2136,6 +2136,17 @@ static struct ssb_sprom bcm63xx_sprom =
+@@ -2128,6 +2128,17 @@ static struct ssb_sprom bcm63xx_sprom =
.boardflags_lo = 0x2848,
.boardflags_hi = 0x0000,
};
#endif
/*
-@@ -2330,8 +2341,9 @@ void __init board_prom_init(void)
+@@ -2328,8 +2339,9 @@ void __init board_prom_init(void)
if (!board_get_mac_address(bcm63xx_sprom.il0mac)) {
memcpy(bcm63xx_sprom.et0mac, bcm63xx_sprom.il0mac, ETH_ALEN);
memcpy(bcm63xx_sprom.et1mac, bcm63xx_sprom.il0mac, ETH_ALEN);
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -2116,7 +2116,7 @@ static void __init nb4_nvram_fixup(void)
+@@ -2108,7 +2108,7 @@ static void __init nb4_nvram_fixup(void)
* bcm4318 WLAN work
*/
#ifdef CONFIG_SSB_PCIHOST
.revision = 0x02,
.board_rev = 0x17,
.country_code = 0x0,
-@@ -2136,6 +2136,7 @@ static struct ssb_sprom bcm63xx_sprom =
+@@ -2128,6 +2128,7 @@ static struct ssb_sprom bcm63xx_sprom =
.boardflags_lo = 0x2848,
.boardflags_hi = 0x0000,
};