1 --- a/arch/mips/bcm47xx/setup.c
2 +++ b/arch/mips/bcm47xx/setup.c
3 @@ -98,6 +98,7 @@ static int bcm47xx_get_sprom_ssb(struct
6 if (bus->bustype == SSB_BUSTYPE_PCI) {
7 + memset(out, 0, sizeof(struct ssb_sprom));
8 snprintf(prefix, sizeof(prefix), "pci/%u/%u/",
9 bus->host_pci->bus->number + 1,
10 PCI_SLOT(bus->host_pci->devfn));
11 @@ -126,6 +127,7 @@ static int bcm47xx_get_invariants(struct
12 if (nvram_getenv("boardrev", buf, sizeof(buf)) >= 0)
13 iv->boardinfo.rev = (u16)simple_strtoul(buf, NULL, 0);
15 + memset(&iv->sprom, 0, sizeof(struct ssb_sprom));
16 bcm47xx_fill_sprom(&iv->sprom, NULL);
18 if (nvram_getenv("cardbus", buf, sizeof(buf)) >= 0)
19 @@ -206,12 +208,14 @@ static int bcm47xx_get_sprom_bcma(struct
21 switch (bus->hosttype) {
22 case BCMA_HOSTTYPE_PCI:
23 + memset(out, 0, sizeof(struct ssb_sprom));
24 snprintf(prefix, sizeof(prefix), "pci/%u/%u/",
25 bus->host_pci->bus->number + 1,
26 PCI_SLOT(bus->host_pci->devfn));
27 bcm47xx_fill_sprom(out, prefix);
29 case BCMA_HOSTTYPE_SOC:
30 + memset(out, 0, sizeof(struct ssb_sprom));
31 bcm47xx_fill_sprom_ethernet(out, NULL);
32 core = bcma_find_core(bus, BCMA_CORE_80211);
34 --- a/arch/mips/bcm47xx/sprom.c
35 +++ b/arch/mips/bcm47xx/sprom.c
36 @@ -555,8 +555,6 @@ void bcm47xx_fill_sprom_ethernet(struct
38 void bcm47xx_fill_sprom(struct ssb_sprom *sprom, const char *prefix)
40 - memset(sprom, 0, sizeof(struct ssb_sprom));
42 bcm47xx_fill_sprom_ethernet(sprom, prefix);
44 nvram_read_u8(prefix, NULL, "sromrev", &sprom->revision, 0);