2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-23 12:43:55 +08:00

korina: disable napi on close and restart

Without this the driver will crash when the NIC is being restarted.

Signed-off-by: Phil Sutter <n0-1@freewrt.org>
Acked-by: Florian Fainelli <florian@openwrt.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Phil Sutter 2009-01-14 21:48:24 -08:00 committed by David S. Miller
parent a13b27826a
commit beb0babfb7

View File

@ -904,6 +904,8 @@ static int korina_restart(struct net_device *dev)
korina_free_ring(dev);
napi_disable(&lp->napi);
ret = korina_init(dev);
if (ret < 0) {
printk(KERN_ERR DRV_NAME "%s: cannot restart device\n",
@ -1070,6 +1072,8 @@ static int korina_close(struct net_device *dev)
korina_free_ring(dev);
napi_disable(&lp->napi);
free_irq(lp->rx_irq, dev);
free_irq(lp->tx_irq, dev);
free_irq(lp->ovr_irq, dev);