Commit 92e44948 authored by Teemu Paasikivi's avatar Teemu Paasikivi Committed by John W. Linville
Browse files

nl80211: Fix exit from nl80211_set_power_save

If interface does not existk, when nl80211_set_power_save is called, (eg.
module has been unloaded) it has been causing kernel panic. Added new
goto target to avoid crash if get_rdev_dev_by_info_ifindex does not
return dev and rdev pointers.
Signed-off-by: default avatarTeemu Paasikivi <>
Signed-off-by: default avatarJohn W. Linville <>
parent 56af3268
......@@ -4990,7 +4990,7 @@ static int nl80211_set_power_save(struct sk_buff *skb, struct genl_info *info)
err = get_rdev_dev_by_info_ifindex(info, &rdev, &dev);
if (err)
goto unlock_rdev;
goto unlock_rtnl;
wdev = dev->ieee80211_ptr;
......@@ -5014,6 +5014,7 @@ static int nl80211_set_power_save(struct sk_buff *skb, struct genl_info *info)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment