aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/tg3.c
diff options
context:
space:
mode:
authorMatt Carlson <mcarlson@broadcom.com>2009-08-28 08:27:50 -0400
committerDavid S. Miller <davem@davemloft.net>2009-08-29 18:42:27 -0400
commit0a9140cff22e405fce1747a2e02d41851c36c55a (patch)
treedb68a54a136cde1920541e252c0c77f0abeef9e1 /drivers/net/tg3.c
parentb3df9a514f3c2020952cff34bc5bc6694a31c00c (diff)
tg3: Delay mdio bus init until fw finishes
The device firmware uses the MDIO bus during early setup. If the driver modifies the MDIO bus configuration while it is in use by the firmware, any number of bad things can happen. This patch delays MDIO setup until after the firmware posts its magic signature, signifying initialization is complete. Signed-off-by: Matt Carlson <mcarlson@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/tg3.c')
-rw-r--r--drivers/net/tg3.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c
index 8af2cdf181dd..ab3159ef4c56 100644
--- a/drivers/net/tg3.c
+++ b/drivers/net/tg3.c
@@ -6348,14 +6348,14 @@ static int tg3_chip_reset(struct tg3 *tp)
6348 tw32_f(MAC_MODE, 0); 6348 tw32_f(MAC_MODE, 0);
6349 udelay(40); 6349 udelay(40);
6350 6350
6351 tg3_mdio_start(tp);
6352
6353 tg3_ape_unlock(tp, TG3_APE_LOCK_GRC); 6351 tg3_ape_unlock(tp, TG3_APE_LOCK_GRC);
6354 6352
6355 err = tg3_poll_fw(tp); 6353 err = tg3_poll_fw(tp);
6356 if (err) 6354 if (err)
6357 return err; 6355 return err;
6358 6356
6357 tg3_mdio_start(tp);
6358
6359 if ((tp->tg3_flags2 & TG3_FLG2_PCI_EXPRESS) && 6359 if ((tp->tg3_flags2 & TG3_FLG2_PCI_EXPRESS) &&
6360 tp->pci_chip_rev_id != CHIPREV_ID_5750_A0) { 6360 tp->pci_chip_rev_id != CHIPREV_ID_5750_A0) {
6361 val = tr32(0x7c00); 6361 val = tr32(0x7c00);