[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20100824220707.GA24183@electric-eye.fr.zoreil.com>
Date: Wed, 25 Aug 2010 00:07:08 +0200
From: Francois Romieu <romieu@...zoreil.com>
To: Alex <alexbtk@....de>
Cc: eric.dumazet@...il.com, rjw@...k.pl, davem@...emloft.net,
adobriyan@...il.com, jpirko@...hat.com, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: Fwd: Re: Linux r8169 interrupt patch
Alex <alexbtk@....de> :
[...]
> I am writing to you, on case of the linux r8169 interrupt bug.
> Sergey gave me your addresses. I assume you can read all the
> neccessary informations below. Please reopen the thread at the
> bugtracker.
> I have several servers running with this chipset and driver. In my
> case, the problem is very critical. Network brokes even every day
> down. I can provide some testing if you would give me some patches
> or solution tips.
Can you send a complete dmesg from boot until problem and give the
patch below a try ?
diff --git a/drivers/net/r8169.c b/drivers/net/r8169.c
index 078bbf4..ec706d2 100644
--- a/drivers/net/r8169.c
+++ b/drivers/net/r8169.c
@@ -4327,13 +4327,13 @@ static netdev_tx_t rtl8169_start_xmit(struct sk_buff *skb,
tp->cur_tx += frags + 1;
- wmb();
-
RTL_W8(TxPoll, NPQ); /* set polling bit */
+ mmiowb();
+
if (TX_BUFFS_AVAIL(tp) < MAX_SKB_FRAGS) {
netif_stop_queue(dev);
- smp_rmb();
+ smp_mb();
if (TX_BUFFS_AVAIL(tp) >= MAX_SKB_FRAGS)
netif_wake_queue(dev);
}
@@ -4428,10 +4428,14 @@ static void rtl8169_tx_interrupt(struct net_device *dev,
if (tp->dirty_tx != dirty_tx) {
tp->dirty_tx = dirty_tx;
- smp_wmb();
- if (netif_queue_stopped(dev) &&
- (TX_BUFFS_AVAIL(tp) >= MAX_SKB_FRAGS)) {
- netif_wake_queue(dev);
+ smp_mb();
+ if (unlikely(netif_queue_stopped(dev) &&
+ (TX_BUFFS_AVAIL(tp) >= (NUM_TX_DESC / 4)))) {
+ netif_tx_lock(dev);
+ if (netif_queue_stopped(dev) &&
+ (TX_BUFFS_AVAIL(tp) >= (NUM_TX_DESC / 4)))
+ netif_wake_queue(dev);
+ netif_tx_unlock(dev);
}
/*
* 8168 hack: TxPoll requests are lost when the Tx packets are
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists