b82032fdae0519703316ad3ede0ecbcc54a6922b
[openwrt.git] / target / linux / brcm63xx / patches-3.2 / 200-spi-board-info.patch
1 --- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
2 +++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
3 @@ -920,6 +920,9 @@ int __init board_register_devices(void)
4         if (board.num_devs)
5                 platform_add_devices(board.devs, board.num_devs);
6  
7 +       if (board.num_spis)
8 +               spi_register_board_info(board.spis, board.num_spis);
9 +
10         /* read base address of boot chip select (0) */
11         val = bcm_mpi_readl(MPI_CSBASE_REG(0));
12         val &= MPI_CSBASE_BASE_MASK;
13 --- a/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
14 +++ b/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
15 @@ -65,6 +65,10 @@ struct board_info {
16         /* Additional platform devices */
17         struct platform_device **devs;
18         unsigned int    num_devs;
19 +
20 +       /* Additional platform devices */
21 +       struct spi_board_info *spis;
22 +       unsigned int    num_spis;
23  };
24  
25  #endif /* ! BOARD_BCM963XX_H_ */