1
0
Fork 0

cfg80211: refuse to .set_monitor_channel when non-monitors are present

Having .set_monitor_channel work with non-monitor
interfaces running would make interface
combinations accounting ambiguous.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
wifi-calibration
Michal Kazior 2012-06-29 12:47:03 +02:00 committed by Johannes Berg
parent 870d37fc22
commit 4f03c1ed89
1 changed files with 2 additions and 0 deletions

View File

@ -85,6 +85,8 @@ int cfg80211_set_monitor_channel(struct cfg80211_registered_device *rdev,
if (!rdev->ops->set_monitor_channel)
return -EOPNOTSUPP;
if (!cfg80211_has_monitors_only(rdev))
return -EBUSY;
chan = rdev_freq_to_chan(rdev, freq, chantype);
if (!chan)