diff options
author | Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com> | 2012-07-08 14:08:10 +0300 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2012-07-08 13:10:07 +0200 |
commit | 56af8f9af99223610f0582594bd4ac0a0320eb71 (patch) | |
tree | 4523f738eac30f8b4ba9ecdb23f36c10fc00cef6 /net/wireless/core.c | |
parent | 2f7916f8d6761e039a117ff560a85a20edb796de (diff) |
cfg80211: fix oops due to unassigned set_monitor_enabled callback
Quick fix for method being invoked without checking its existence.
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/wireless/core.c')
-rw-r--r-- | net/wireless/core.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/net/wireless/core.c b/net/wireless/core.c index eb60410ae58..e42a97b5b97 100644 --- a/net/wireless/core.c +++ b/net/wireless/core.c @@ -774,8 +774,9 @@ void cfg80211_update_iface_num(struct cfg80211_registered_device *rdev, has_monitors_only_new = cfg80211_has_monitors_only(rdev); if (has_monitors_only_new != has_monitors_only_old) { - rdev->ops->set_monitor_enabled(&rdev->wiphy, - has_monitors_only_new); + if (rdev->ops->set_monitor_enabled) + rdev->ops->set_monitor_enabled(&rdev->wiphy, + has_monitors_only_new); if (!has_monitors_only_new) { rdev->monitor_channel = NULL; |