In the new nl80211_dump_wiphy() handling I forgot to properly
unlock the RTNL (again!), fix that.
Reported-by: Stephen Rothwell <[email protected]>
Signed-off-by: Johannes Berg <[email protected]>
---
net/wireless/nl80211.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 785761f..66382b1 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -1568,8 +1568,10 @@ static int nl80211_dump_wiphy(struct sk_buff *skb, struct netlink_callback *cb)
rtnl_lock();
if (!state) {
state = kzalloc(sizeof(*state), GFP_KERNEL);
- if (!state)
+ if (!state) {
+ rtnl_unlock();
return -ENOMEM;
+ }
state->filter_wiphy = -1;
ret = nl80211_dump_wiphy_parse(skb, cb, state);
if (ret) {
--
1.8.0