提交 7f230735 编写于 作者: M Matt Carlson 提交者: David S. Miller

tg3: Fix missed MSI workaround

This patch fixes a minor counter initialization bug and makes the MSI
workaround slightly more efficient by attempting to service pending
interrupts before applying the workaround.
Signed-off-by: NMatt Carlson <mcarlson@broadcom.com>
Reviewed-by: NBenjamin Li <benli@broadcom.com>
Reviewed-by: NMichael Chan <mchan@broadcom.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 b99d2a57
...@@ -8105,7 +8105,7 @@ static void tg3_rings_reset(struct tg3 *tp) ...@@ -8105,7 +8105,7 @@ static void tg3_rings_reset(struct tg3 *tp)
tw32_mailbox(tp->napi[i].prodmbox, 0); tw32_mailbox(tp->napi[i].prodmbox, 0);
tw32_rx_mbox(tp->napi[i].consmbox, 0); tw32_rx_mbox(tp->napi[i].consmbox, 0);
tw32_mailbox_f(tp->napi[i].int_mbox, 1); tw32_mailbox_f(tp->napi[i].int_mbox, 1);
tp->napi[0].chk_msi_cnt = 0; tp->napi[i].chk_msi_cnt = 0;
tp->napi[i].last_rx_cons = 0; tp->napi[i].last_rx_cons = 0;
tp->napi[i].last_tx_cons = 0; tp->napi[i].last_tx_cons = 0;
} }
...@@ -9185,8 +9185,7 @@ static void tg3_chk_missed_msi(struct tg3 *tp) ...@@ -9185,8 +9185,7 @@ static void tg3_chk_missed_msi(struct tg3 *tp)
tnapi->chk_msi_cnt++; tnapi->chk_msi_cnt++;
return; return;
} }
tw32_mailbox(tnapi->int_mbox, tg3_msi(0, tnapi);
tnapi->last_tag << 24);
} }
} }
tnapi->chk_msi_cnt = 0; tnapi->chk_msi_cnt = 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册
新手
引导
客服 返回
顶部