Commit e8296582 authored by Benjamin Herrenschmidt's avatar Benjamin Herrenschmidt Committed by Jeff Garzik

ibm_newemac: Don't call dev_mc_add() before device is registered

We must not call dev_mc_add() from within our HW configure which happens
before we initialize and register the netdev. Do it in open() instead.

Thanks to Sebastian Siewior for tracking it down.
Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: default avatarJeff Garzik <jgarzik@redhat.com>
parent ab939905
...@@ -663,9 +663,6 @@ static int emac_configure(struct emac_instance *dev) ...@@ -663,9 +663,6 @@ static int emac_configure(struct emac_instance *dev)
if (emac_phy_gpcs(dev->phy.mode)) if (emac_phy_gpcs(dev->phy.mode))
emac_mii_reset_phy(&dev->phy); emac_mii_reset_phy(&dev->phy);
/* Required for Pause packet support in EMAC */
dev_mc_add(ndev, default_mcast_addr, sizeof(default_mcast_addr), 1);
return 0; return 0;
} }
...@@ -1150,6 +1147,9 @@ static int emac_open(struct net_device *ndev) ...@@ -1150,6 +1147,9 @@ static int emac_open(struct net_device *ndev)
} else } else
netif_carrier_on(dev->ndev); netif_carrier_on(dev->ndev);
/* Required for Pause packet support in EMAC */
dev_mc_add(ndev, default_mcast_addr, sizeof(default_mcast_addr), 1);
emac_configure(dev); emac_configure(dev);
mal_poll_add(dev->mal, &dev->commac); mal_poll_add(dev->mal, &dev->commac);
mal_enable_tx_channel(dev->mal, dev->mal_tx_chan); mal_enable_tx_channel(dev->mal, dev->mal_tx_chan);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment