Changeset 33209


Ignore:
Timestamp:
2012-08-18T16:08:35+02:00 (5 years ago)
Author:
hauke
Message:

[brcm47xx] make brcm47xx build only with bcma or only with ssb support.

There are some ifdefs missing so when only ssb or only bcma was
selected in the kernel config it did not build.

Location:
trunk/target/linux/brcm47xx/patches-3.3
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/target/linux/brcm47xx/patches-3.3/024-brcm47xx-add-common-interface-for-sflash.patch

    r32845 r33209  
    1010--- /dev/null 
    1111+++ b/arch/mips/bcm47xx/bus.c 
    12 @@ -0,0 +1,82 @@ 
     12@@ -0,0 +1,86 @@ 
    1313+/* 
    1414+ * BCM947xx nvram variable access 
     
    2424+#include <bus.h> 
    2525+ 
     26+#ifdef CONFIG_BCM47XX_BCMA 
    2627+static int bcm47xx_sflash_bcma_read(struct bcm47xx_sflash *dev, u32 offset, u32 len, u8 *buf) 
    2728+{ 
     
    5859+       sflash->size = bcc->sflash.size; 
    5960+} 
     61+#endif 
    6062+ 
     63+#ifdef CONFIG_BCM47XX_SSB 
    6164+static int bcm47xx_sflash_ssb_read(struct bcm47xx_sflash *dev, u32 offset, u32 len, u8 *buf) 
    6265+{ 
     
    9396+       sflash->size = scc->sflash.size; 
    9497+} 
     98+#endif 
    9599--- a/arch/mips/bcm47xx/setup.c 
    96100+++ b/arch/mips/bcm47xx/setup.c 
  • trunk/target/linux/brcm47xx/patches-3.3/027-mtd-bcm47xx-add-serial-flash-driver.patch

    r31573 r33209  
    1 --- a/arch/mips/include/asm/mach-bcm47xx/bus.h 
    2 +++ b/arch/mips/include/asm/mach-bcm47xx/bus.h 
    3 @@ -11,6 +11,7 @@ 
    4   
    5  #include <linux/ssb/ssb.h> 
    6  #include <linux/bcma/bcma.h> 
    7 +#include <linux/mtd/mtd.h> 
    8  #include <bcm47xx.h> 
    9   
    10  struct bcm47xx_sflash { 
    11 @@ -28,6 +29,8 @@ struct bcm47xx_sflash { 
    12         u32 blocksize;          /* Block size */ 
    13         u32 numblocks;          /* Number of blocks */ 
    14         u32 size;               /* Total size in bytes */ 
    15 + 
    16 +       struct mtd_info *mtd; 
    17  }; 
    18   
    19  void bcm47xx_sflash_struct_bcma_init(struct bcm47xx_sflash *sflash, struct bcma_drv_cc *bcc); 
    201--- a/drivers/mtd/maps/Kconfig 
    212+++ b/drivers/mtd/maps/Kconfig 
  • trunk/target/linux/brcm47xx/patches-3.3/030-bcm47xx-bcma-nandflash.patch

    r32845 r33209  
    1919  * This program is free software; you can redistribute  it and/or modify it 
    2020  * under  the terms of  the GNU General  Public License as published by the 
    21 @@ -80,3 +81,9 @@ void bcm47xx_sflash_struct_ssb_init(stru 
    22         sflash->numblocks = scc->sflash.numblocks; 
    23         sflash->size = scc->sflash.size; 
     21@@ -46,6 +47,12 @@ void bcm47xx_sflash_struct_bcma_init(str 
     22        sflash->numblocks = bcc->sflash.numblocks; 
     23        sflash->size = bcc->sflash.size; 
    2424 } 
    2525+ 
     
    2929+       nflash->bcc = bcc; 
    3030+} 
     31 #endif 
     32  
     33 #ifdef CONFIG_BCM47XX_SSB 
    3134--- a/arch/mips/bcm47xx/nvram.c 
    3235+++ b/arch/mips/bcm47xx/nvram.c 
     
    4750 static char nvram_buf[NVRAM_SPACE]; 
    4851  
    49 @@ -139,6 +141,51 @@ static int early_nvram_init_sflash(void) 
    50         return 0; 
    51  } 
    52   
     52@@ -160,6 +162,51 @@ static void early_nvram_init_ssb(void) 
     53 #endif 
     54  
     55 #ifdef CONFIG_BCM47XX_BCMA 
    5356+static int early_nvram_init_nflash(void) 
    5457+{ 
     
    9699+} 
    97100+ 
    98  #ifdef CONFIG_BCM47XX_SSB 
    99  static void early_nvram_init_ssb(void) 
     101 static void early_nvram_init_bcma(void) 
    100102 { 
     103        int err; 
    101104@@ -173,6 +220,11 @@ static void early_nvram_init_bcma(void) 
    102105                if (err < 0) 
     
    121124  *  This program is free software; you can redistribute  it and/or modify it 
    122125  *  under  the terms of  the GNU General  Public License as published by the 
    123 @@ -46,6 +47,7 @@ enum bcm47xx_bus_type bcm47xx_bus_type; 
    124  EXPORT_SYMBOL(bcm47xx_bus_type); 
    125   
    126  struct bcm47xx_sflash bcm47xx_sflash; 
     126@@ -234,6 +235,21 @@ static int bcm47xx_get_sprom_bcma(struct 
     127        } 
     128 } 
     129  
    127130+struct bcm47xx_nflash bcm47xx_nflash; 
    128   
    129  static struct resource bcm47xx_pflash_resource = { 
    130         .name   = "bcm47xx_pflash", 
    131 @@ -73,6 +75,19 @@ static struct platform_device bcm47xx_sf 
    132         .num_resources  = 1, 
    133  }; 
    134   
     131+ 
    135132+static struct resource bcm47xx_nflash_resource = { 
    136133+       .name   = "bcm47xx_nflash", 
     
    146143+}; 
    147144+ 
    148  static void bcm47xx_machine_restart(char *command) 
     145 static void __init bcm47xx_register_bcma(void) 
    149146 { 
    150         printk(KERN_ALERT "Please stand by while rebooting the system...\n"); 
    151 @@ -248,6 +263,9 @@ static void __init bcm47xx_register_bcma 
     147        int err; 
     148@@ -248,6 +264,9 @@ static void __init bcm47xx_register_bcma 
    152149  
    153150        if (bcm47xx_bus.bcma.bus.drv_cc.flash_type == BCMA_SFLASH) 
     
    159156        bcm47xx_fill_bcma_boardinfo(&bcm47xx_bus.bcma.bus.boardinfo, NULL); 
    160157 } 
    161 @@ -264,6 +282,9 @@ static int __init bcm47xx_register_flash 
     158@@ -264,6 +283,9 @@ static int __init bcm47xx_register_flash 
    162159        case BCMA_SFLASH: 
    163160                bcm47xx_sflash_dev.dev.platform_data = &bcm47xx_sflash; 
     
    179176  * This program is free software; you can redistribute  it and/or modify it 
    180177  * under  the terms of  the GNU General  Public License as published by the 
    181 @@ -13,6 +14,7 @@ 
     178@@ -12,6 +13,7 @@ 
     179 #include <linux/ssb/ssb.h> 
    182180 #include <linux/bcma/bcma.h> 
    183  #include <linux/mtd/mtd.h> 
    184181 #include <bcm47xx.h> 
    185182+#include <linux/mtd/nand.h> 
     
    187184 struct bcm47xx_sflash { 
    188185        enum bcm47xx_bus_type sflash_type; 
    189 @@ -29,11 +31,24 @@ struct bcm47xx_sflash { 
    190         u32 blocksize;          /* Block size */ 
    191         u32 numblocks;          /* Number of blocks */ 
    192         u32 size;               /* Total size in bytes */ 
    193 - 
    194 -       struct mtd_info *mtd; 
    195  }; 
    196   
    197  void bcm47xx_sflash_struct_bcma_init(struct bcm47xx_sflash *sflash, struct bcma_drv_cc *bcc); 
     186@@ -34,3 +36,18 @@ void bcm47xx_sflash_struct_bcma_init(str 
    198187 void bcm47xx_sflash_struct_ssb_init(struct bcm47xx_sflash *sflash, struct ssb_chipcommon *scc); 
    199188  
     
    446435+       tristate "bcm47xx nand flash support" 
    447436+       default y 
    448 +       depends on BCM47XX 
     437+       depends on BCM47XX && BCMA_NFLASH 
    449438+       select MTD_PARTITIONS 
    450439+       help 
  • trunk/target/linux/brcm47xx/patches-3.3/114-MIPS-BCM47xx-Setup-and-register-serial-early.patch

    r32845 r33209  
    2525 #include <asm/reboot.h> 
    2626 #include <asm/time.h> 
    27 @@ -166,6 +168,31 @@ static int bcm47xx_get_invariants(struct 
     27@@ -152,6 +154,31 @@ static int bcm47xx_get_invariants(struct 
    2828        return 0; 
    2929 } 
     
    5757 { 
    5858        int err; 
    59 @@ -198,6 +225,10 @@ static void __init bcm47xx_register_ssb( 
     59@@ -184,6 +211,10 @@ static void __init bcm47xx_register_ssb( 
    6060                        memcpy(&mcore->serial_ports[1], &port, sizeof(port)); 
    6161                } 
  • trunk/target/linux/brcm47xx/patches-3.3/400-arch-bcm47xx.patch

    r31790 r33209  
    3434--- a/arch/mips/bcm47xx/setup.c 
    3535+++ b/arch/mips/bcm47xx/setup.c 
    36 @@ -379,3 +379,20 @@ static int __init bcm47xx_register_flash 
     36@@ -380,3 +380,20 @@ static int __init bcm47xx_register_flash 
    3737        return -1; 
    3838 } 
  • trunk/target/linux/brcm47xx/patches-3.3/502-bcm47xx-rewrite-gpio-handling.patch

    r33208 r33209  
    273273--- a/arch/mips/bcm47xx/setup.c 
    274274+++ b/arch/mips/bcm47xx/setup.c 
    275 @@ -344,6 +344,8 @@ void __init plat_mem_setup(void) 
     275@@ -345,6 +345,8 @@ void __init plat_mem_setup(void) 
    276276        _machine_restart = bcm47xx_machine_restart; 
    277277        _machine_halt = bcm47xx_machine_halt; 
  • trunk/target/linux/brcm47xx/patches-3.3/980-wnr834b_no_cardbus_invariant.patch

    r31772 r33209  
    11--- a/arch/mips/bcm47xx/setup.c 
    22+++ b/arch/mips/bcm47xx/setup.c 
    3 @@ -165,6 +165,10 @@ static int bcm47xx_get_invariants(struct 
     3@@ -151,6 +151,10 @@ static int bcm47xx_get_invariants(struct 
    44        if (nvram_getenv("cardbus", buf, sizeof(buf)) >= 0) 
    55                iv->has_cardbus_slot = !!simple_strtoul(buf, NULL, 10); 
Note: See TracChangeset for help on using the changeset viewer.