aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/net/r8169.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/net/r8169.c b/drivers/net/r8169.c
index 78c1d5832792..dff0bf094168 100644
--- a/drivers/net/r8169.c
+++ b/drivers/net/r8169.c
@@ -407,6 +407,7 @@ enum rtl_register_content {
407 RxOK = 0x0001, 407 RxOK = 0x0001,
408 408
409 /* RxStatusDesc */ 409 /* RxStatusDesc */
410 RxBOVF = (1 << 24),
410 RxFOVF = (1 << 23), 411 RxFOVF = (1 << 23),
411 RxRWT = (1 << 22), 412 RxRWT = (1 << 22),
412 RxRES = (1 << 21), 413 RxRES = (1 << 21),
@@ -682,6 +683,7 @@ struct rtl8169_private {
682 struct mii_if_info mii; 683 struct mii_if_info mii;
683 struct rtl8169_counters counters; 684 struct rtl8169_counters counters;
684 u32 saved_wolopts; 685 u32 saved_wolopts;
686 u32 opts1_mask;
685 687
686 struct rtl_fw { 688 struct rtl_fw {
687 const struct firmware *fw; 689 const struct firmware *fw;
@@ -3786,6 +3788,9 @@ rtl8169_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
3786 tp->intr_event = cfg->intr_event; 3788 tp->intr_event = cfg->intr_event;
3787 tp->napi_event = cfg->napi_event; 3789 tp->napi_event = cfg->napi_event;
3788 3790
3791 tp->opts1_mask = (tp->mac_version != RTL_GIGA_MAC_VER_01) ?
3792 ~(RxBOVF | RxFOVF) : ~0;
3793
3789 init_timer(&tp->timer); 3794 init_timer(&tp->timer);
3790 tp->timer.data = (unsigned long) dev; 3795 tp->timer.data = (unsigned long) dev;
3791 tp->timer.function = rtl8169_phy_timer; 3796 tp->timer.function = rtl8169_phy_timer;
@@ -5324,7 +5329,7 @@ static int rtl8169_rx_interrupt(struct net_device *dev,
5324 u32 status; 5329 u32 status;
5325 5330
5326 rmb(); 5331 rmb();
5327 status = le32_to_cpu(desc->opts1); 5332 status = le32_to_cpu(desc->opts1) & tp->opts1_mask;
5328 5333
5329 if (status & DescOwn) 5334 if (status & DescOwn)
5330 break; 5335 break;