| To: | akpm@xxxxxxxx |
|---|---|
| Subject: | [patch 1/5] r8169: missing netif_poll_enable and irq ack |
| From: | Francois Romieu <romieu@xxxxxxxxxxxxx> |
| Date: | Tue, 7 Dec 2004 01:14:19 +0100 |
| Cc: | netdev@xxxxxxxxxxx, jgarzik@xxxxxxxxx, Dorn Hetzel <kernel@xxxxxxxxxxxxxxx> |
| In-reply-to: | <20041205233756.GB29236@xxxxxxxxxxxxxxxxxxxxxxxxxx> |
| References: | <20041119162920.GA26836@xxxxxxxxxxxxxxxx> <20041119201203.GA13522@xxxxxxxxxxxxxxxxxxxxxxxxxx> <20041120003754.GA32133@xxxxxxxxxxxxxxxx> <20041120002946.GA18059@xxxxxxxxxxxxxxxxxxxxxxxxxx> <20041122181307.GA3625@xxxxxxxxxxxxxxxx> <20041205235519.GA21885@xxxxxxxxxxxxxxxx> <20041205233756.GB29236@xxxxxxxxxxxxxxxxxxxxxxxxxx> |
| Sender: | netdev-bounce@xxxxxxxxxxx |
| User-agent: | Mutt/1.4.1i |
- (noticed by Jon D. Mason) rtl8169_wait_for_quiescence() needs to disable
the NAPI processing but it has no reason to lock any part of the driver
which would try to do the same at a later time. Let's reenable NAPI
processing as soon as possible.
- properly ack any aborted interruption: a reset of the device is not
always enough.
Signed-off-by: Francois Romieu <romieu@xxxxxxxxxxxxx>
diff -puN drivers/net/r8169.c~r8169-250 drivers/net/r8169.c
--- linux-2.6.10-rc2/drivers/net/r8169.c~r8169-250 2004-12-05
22:36:14.592843434 +0100
+++ linux-2.6.10-rc2-fr/drivers/net/r8169.c 2004-12-05 22:36:14.596842782
+0100
@@ -1742,10 +1742,19 @@ static void rtl8169_schedule_work(struct
static void rtl8169_wait_for_quiescence(struct net_device *dev)
{
+ struct rtl8169_private *tp = netdev_priv(dev);
+ void __iomem *ioaddr = tp->mmio_addr;
+
synchronize_irq(dev->irq);
/* Wait for any pending NAPI task to complete */
netif_poll_disable(dev);
+
+ RTL_W16(IntrMask, 0x0000);
+
+ RTL_W16(IntrStatus, 0xffff);
+
+ netif_poll_enable(dev);
}
static void rtl8169_reinit_task(void *_data)
_
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: _High_ CPU usage while routing (mostly) small UDP packets, Con Kolivas |
|---|---|
| Next by Date: | Re: _High_ CPU usage while routing (mostly) small UDP packets, Karsten Desler |
| Previous by Thread: | Re: r8169.c, Francois Romieu |
| Next by Thread: | [patch 2/5] r8169: C 101, Francois Romieu |
| Indexes: | [Date] [Thread] [Top] [All Lists] |