|
@@ -1800,6 +1800,9 @@ static int tg3_poll_fw(struct tg3 *tp)
|
|
int i;
|
|
int i;
|
|
u32 val;
|
|
u32 val;
|
|
|
|
|
|
|
|
+ if (tg3_flag(tp, NO_FWARE_REPORTED))
|
|
|
|
+ return 0;
|
|
|
|
+
|
|
if (tg3_flag(tp, IS_SSB_CORE)) {
|
|
if (tg3_flag(tp, IS_SSB_CORE)) {
|
|
/* We don't use firmware. */
|
|
/* We don't use firmware. */
|
|
return 0;
|
|
return 0;
|
|
@@ -10404,6 +10407,13 @@ static int tg3_reset_hw(struct tg3 *tp, bool reset_phy)
|
|
*/
|
|
*/
|
|
static int tg3_init_hw(struct tg3 *tp, bool reset_phy)
|
|
static int tg3_init_hw(struct tg3 *tp, bool reset_phy)
|
|
{
|
|
{
|
|
|
|
+ /* Chip may have been just powered on. If so, the boot code may still
|
|
|
|
+ * be running initialization. Wait for it to finish to avoid races in
|
|
|
|
+ * accessing the hardware.
|
|
|
|
+ */
|
|
|
|
+ tg3_enable_register_access(tp);
|
|
|
|
+ tg3_poll_fw(tp);
|
|
|
|
+
|
|
tg3_switch_clocks(tp);
|
|
tg3_switch_clocks(tp);
|
|
|
|
|
|
tw32(TG3PCI_MEM_WIN_BASE_ADDR, 0);
|
|
tw32(TG3PCI_MEM_WIN_BASE_ADDR, 0);
|