[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20070620105802.GC9454@de.ibm.com>
Date: Wed, 20 Jun 2007 12:58:02 +0200
From: Frank Pavlic <fpavlic@...ibm.com>
To: jgarzik@...ox.com
Cc: netdev@...r.kernel.org
Subject: [PATCH 3/8] s390: avoid inconsistent lock state in qeth
From: Ursula Braun <braunu@...ibm.com>
ipv6_regen_rndid in net/ipv6/addrconf.c makes use of "write_lock_bh"
for its inet6_dev->lock. It may run in softirq-context.
qeth makes use of "read_lock" for the same inet6_dev->lock.
To avoid a potential deadlock situation, qeth should make use of
"read_lock_bh" for its usages of inet6_dev->lock.
Signed-off-by: Ursula Braun <braunu@...ibm.com>
Signed-off-by: Frank Pavlic <fpavlic@...ibm.com>
---
drivers/s390/net/qeth_main.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/s390/net/qeth_main.c b/drivers/s390/net/qeth_main.c
index c5a9507..79b7379 100644
--- a/drivers/s390/net/qeth_main.c
+++ b/drivers/s390/net/qeth_main.c
@@ -5850,9 +5850,9 @@ qeth_add_vlan_mc6(struct qeth_card *card)
in_dev = in6_dev_get(netdev);
if (!in_dev)
continue;
- read_lock(&in_dev->lock);
+ read_lock_bh(&in_dev->lock);
qeth_add_mc6(card,in_dev);
- read_unlock(&in_dev->lock);
+ read_unlock_bh(&in_dev->lock);
in6_dev_put(in_dev);
}
#endif /* CONFIG_QETH_VLAN */
@@ -5869,10 +5869,10 @@ qeth_add_multicast_ipv6(struct qeth_card *card)
in6_dev = in6_dev_get(card->dev);
if (in6_dev == NULL)
return;
- read_lock(&in6_dev->lock);
+ read_lock_bh(&in6_dev->lock);
qeth_add_mc6(card, in6_dev);
qeth_add_vlan_mc6(card);
- read_unlock(&in6_dev->lock);
+ read_unlock_bh(&in6_dev->lock);
in6_dev_put(in6_dev);
}
#endif /* CONFIG_QETH_IPV6 */
--
1.5.2.1
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists