summaryrefslogtreecommitdiffstats
path: root/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.24/0087-r8169-call-netif_napi_del-at-errpaths-and-at-driver-.patch
diff options
context:
space:
mode:
Diffstat (limited to 'recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.24/0087-r8169-call-netif_napi_del-at-errpaths-and-at-driver-.patch')
-rw-r--r--recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.24/0087-r8169-call-netif_napi_del-at-errpaths-and-at-driver-.patch43
1 files changed, 43 insertions, 0 deletions
diff --git a/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.24/0087-r8169-call-netif_napi_del-at-errpaths-and-at-driver-.patch b/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.24/0087-r8169-call-netif_napi_del-at-errpaths-and-at-driver-.patch
new file mode 100644
index 00000000..8fd5527a
--- /dev/null
+++ b/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.24/0087-r8169-call-netif_napi_del-at-errpaths-and-at-driver-.patch
@@ -0,0 +1,43 @@
1From 87b62a139d4385f3726820674127eaee29fc7cff Mon Sep 17 00:00:00 2001
2From: Devendra Naga <devendra.aaru@gmail.com>
3Date: Thu, 31 May 2012 01:51:20 +0000
4Subject: [PATCH 087/109] r8169: call netif_napi_del at errpaths and at driver
5 unload
6
7commit ad1be8d345416a794dea39761a374032aa471a76 upstream.
8
9when register_netdev fails, the init'ed NAPIs by netif_napi_add must be
10deleted with netif_napi_del, and also when driver unloads, it should
11delete the NAPI before unregistering netdevice using unregister_netdev.
12
13Signed-off-by: Devendra Naga <devendra.aaru@gmail.com>
14Signed-off-by: David S. Miller <davem@davemloft.net>
15Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
16---
17 drivers/net/ethernet/realtek/r8169.c | 3 +++
18 1 files changed, 3 insertions(+), 0 deletions(-)
19
20diff --git a/drivers/net/ethernet/realtek/r8169.c b/drivers/net/ethernet/realtek/r8169.c
21index cc2565c..9e61d6b 100644
22--- a/drivers/net/ethernet/realtek/r8169.c
23+++ b/drivers/net/ethernet/realtek/r8169.c
24@@ -4185,6 +4185,7 @@ out:
25 return rc;
26
27 err_out_msi_4:
28+ netif_napi_del(&tp->napi);
29 rtl_disable_msi(pdev, tp);
30 iounmap(ioaddr);
31 err_out_free_res_3:
32@@ -4210,6 +4211,8 @@ static void __devexit rtl8169_remove_one(struct pci_dev *pdev)
33
34 cancel_delayed_work_sync(&tp->task);
35
36+ netif_napi_del(&tp->napi);
37+
38 unregister_netdev(dev);
39
40 rtl_release_firmware(tp);
41--
421.7.7.6
43