linux-s390.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net 0/1] qeth: important fix to avoid panic on oops
@ 2016-07-04 12:07 Ursula Braun
  2016-07-04 12:07 ` [PATCH net 1/1] qeth: delete napi struct when removing a qeth device Ursula Braun
  0 siblings, 1 reply; 3+ messages in thread
From: Ursula Braun @ 2016-07-04 12:07 UTC (permalink / raw)
  To: davem; +Cc: netdev, linux-s390, stable, schwidefsky, heiko.carstens, utz.bacher

Dave,

here is an important qeth patch built for the net-tree fixing a qeth crash.

Thanks, Ursula

Ursula Braun (1):
  Subject: [PATCH] qeth: delete napi struct when removing a qeth device

 drivers/s390/net/qeth_l2_main.c | 1 +
 drivers/s390/net/qeth_l3_main.c | 1 +
 2 files changed, 2 insertions(+)

-- 
2.6.6

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH net 1/1] qeth: delete napi struct when removing a qeth device
  2016-07-04 12:07 [PATCH net 0/1] qeth: important fix to avoid panic on oops Ursula Braun
@ 2016-07-04 12:07 ` Ursula Braun
  2016-07-05  6:33   ` David Miller
  0 siblings, 1 reply; 3+ messages in thread
From: Ursula Braun @ 2016-07-04 12:07 UTC (permalink / raw)
  To: davem; +Cc: netdev, linux-s390, stable, schwidefsky, heiko.carstens, utz.bacher

A qeth_card contains a napi_struct linked to the net_device during
device probing. This struct must be deleted when removing the qeth
device, otherwise Panic on oops can occur when qeth devices are
repeatedly removed and added.

Fixes: a1c3ed4c9ca ("qeth: NAPI support for l2 and l3 discipline")
Cc: stable@vger.kernel.org # v2.6.37+
Signed-off-by: Ursula Braun <ubraun@linux.vnet.ibm.com>
Tested-by: Alexander Klein <ALKL@de.ibm.com>
---
 drivers/s390/net/qeth_l2_main.c | 1 +
 drivers/s390/net/qeth_l3_main.c | 1 +
 2 files changed, 2 insertions(+)

diff --git a/drivers/s390/net/qeth_l2_main.c b/drivers/s390/net/qeth_l2_main.c
index 80b1979..df036b8 100644
--- a/drivers/s390/net/qeth_l2_main.c
+++ b/drivers/s390/net/qeth_l2_main.c
@@ -1051,6 +1051,7 @@ static void qeth_l2_remove_device(struct ccwgroup_device *cgdev)
 		qeth_l2_set_offline(cgdev);
 
 	if (card->dev) {
+		netif_napi_del(&card->napi);
 		unregister_netdev(card->dev);
 		card->dev = NULL;
 	}
diff --git a/drivers/s390/net/qeth_l3_main.c b/drivers/s390/net/qeth_l3_main.c
index ac54433..709b523 100644
--- a/drivers/s390/net/qeth_l3_main.c
+++ b/drivers/s390/net/qeth_l3_main.c
@@ -3226,6 +3226,7 @@ static void qeth_l3_remove_device(struct ccwgroup_device *cgdev)
 		qeth_l3_set_offline(cgdev);
 
 	if (card->dev) {
+		netif_napi_del(&card->napi);
 		unregister_netdev(card->dev);
 		card->dev = NULL;
 	}
-- 
2.6.6

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH net 1/1] qeth: delete napi struct when removing a qeth device
  2016-07-04 12:07 ` [PATCH net 1/1] qeth: delete napi struct when removing a qeth device Ursula Braun
@ 2016-07-05  6:33   ` David Miller
  0 siblings, 0 replies; 3+ messages in thread
From: David Miller @ 2016-07-05  6:33 UTC (permalink / raw)
  To: ubraun
  Cc: netdev, linux-s390, stable, schwidefsky, heiko.carstens, utz.bacher

From: Ursula Braun <ubraun@linux.vnet.ibm.com>
Date: Mon,  4 Jul 2016 14:07:16 +0200

> A qeth_card contains a napi_struct linked to the net_device during
> device probing. This struct must be deleted when removing the qeth
> device, otherwise Panic on oops can occur when qeth devices are
> repeatedly removed and added.
> 
> Fixes: a1c3ed4c9ca ("qeth: NAPI support for l2 and l3 discipline")
> Cc: stable@vger.kernel.org # v2.6.37+
> Signed-off-by: Ursula Braun <ubraun@linux.vnet.ibm.com>
> Tested-by: Alexander Klein <ALKL@de.ibm.com>

Applied, thanks.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-07-05  6:33 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-04 12:07 [PATCH net 0/1] qeth: important fix to avoid panic on oops Ursula Braun
2016-07-04 12:07 ` [PATCH net 1/1] qeth: delete napi struct when removing a qeth device Ursula Braun
2016-07-05  6:33   ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).