aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/bcma/main.c
diff options
context:
space:
mode:
authorRafał Miłecki <zajec5@gmail.com>2012-07-11 03:23:43 -0400
committerJohn W. Linville <linville@tuxdriver.com>2012-07-12 15:27:18 -0400
commite1ac4b409037b128f9a3eca3b3ab5dbbb71a7e6f (patch)
tree33eb5d7bb0751f17f0968bdd29901df1807797fd /drivers/bcma/main.c
parent97cfda8fecacc40c5652b0924c4c0f5ab508dc9a (diff)
bcma: add trivial GBIT MAC COMMON driver
GMAC COMMON core is present on BCM4706 and is used for example to access board PHYs (PHYs can not be accessed directly using GBIT MAC core). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Acked-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/bcma/main.c')
-rw-r--r--drivers/bcma/main.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/bcma/main.c b/drivers/bcma/main.c
index 151bddc57e16..758af9ccdef0 100644
--- a/drivers/bcma/main.c
+++ b/drivers/bcma/main.c
@@ -103,6 +103,7 @@ static int bcma_register_cores(struct bcma_bus *bus)
103 case BCMA_CORE_PCI: 103 case BCMA_CORE_PCI:
104 case BCMA_CORE_PCIE: 104 case BCMA_CORE_PCIE:
105 case BCMA_CORE_MIPS_74K: 105 case BCMA_CORE_MIPS_74K:
106 case BCMA_CORE_4706_MAC_GBIT_COMMON:
106 continue; 107 continue;
107 } 108 }
108 109
@@ -185,6 +186,13 @@ int __devinit bcma_bus_register(struct bcma_bus *bus)
185 bcma_core_pci_init(&bus->drv_pci); 186 bcma_core_pci_init(&bus->drv_pci);
186 } 187 }
187 188
189 /* Init GBIT MAC COMMON core */
190 core = bcma_find_core(bus, BCMA_CORE_4706_MAC_GBIT_COMMON);
191 if (core) {
192 bus->drv_gmac_cmn.core = core;
193 bcma_core_gmac_cmn_init(&bus->drv_gmac_cmn);
194 }
195
188 /* Try to get SPROM */ 196 /* Try to get SPROM */
189 err = bcma_sprom_get(bus); 197 err = bcma_sprom_get(bus);
190 if (err == -ENOENT) { 198 if (err == -ENOENT) {