]> git.karo-electronics.de Git - linux-beck.git/commitdiff
bgmac: fix device initialization on Northstar SoCs (condition typo)
authorRafał Miłecki <zajec5@gmail.com>
Wed, 11 Feb 2015 17:06:34 +0000 (18:06 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 12 Feb 2015 03:44:21 +0000 (19:44 -0800)
On Northstar (Broadcom's ARM architecture) we need to manually enable
all cores. Code for that is already in place, but the condition for it
was wrong.

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/bgmac.c

index ea63cb085d19bec501c804fda174db954958a9d1..676ffe09318073e33b707d46423bdcf780451750 100644 (file)
@@ -1412,6 +1412,7 @@ static void bgmac_mii_unregister(struct bgmac *bgmac)
 /* http://bcm-v4.sipsolutions.net/mac-gbit/gmac/chipattach */
 static int bgmac_probe(struct bcma_device *core)
 {
+       struct bcma_chipinfo *ci = &core->bus->chipinfo;
        struct net_device *net_dev;
        struct bgmac *bgmac;
        struct ssb_sprom *sprom = &core->bus->sprom;
@@ -1474,8 +1475,8 @@ static int bgmac_probe(struct bcma_device *core)
        bgmac_chip_reset(bgmac);
 
        /* For Northstar, we have to take all GMAC core out of reset */
-       if (core->id.id == BCMA_CHIP_ID_BCM4707 ||
-           core->id.id == BCMA_CHIP_ID_BCM53018) {
+       if (ci->id == BCMA_CHIP_ID_BCM4707 ||
+           ci->id == BCMA_CHIP_ID_BCM53018) {
                struct bcma_device *ns_core;
                int ns_gmac;