diff options
Diffstat (limited to 'net/mac80211/ieee80211_ioctl.c')
-rw-r--r-- | net/mac80211/ieee80211_ioctl.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/net/mac80211/ieee80211_ioctl.c b/net/mac80211/ieee80211_ioctl.c index bbd9bc572a54..dc03bd796fee 100644 --- a/net/mac80211/ieee80211_ioctl.c +++ b/net/mac80211/ieee80211_ioctl.c | |||
@@ -315,7 +315,7 @@ int ieee80211_set_channel(struct ieee80211_local *local, int channel, int freq) | |||
315 | } | 315 | } |
316 | 316 | ||
317 | if (set) { | 317 | if (set) { |
318 | if (local->sta_scanning) | 318 | if (local->sta_sw_scanning) |
319 | ret = 0; | 319 | ret = 0; |
320 | else | 320 | else |
321 | ret = ieee80211_hw_config(local); | 321 | ret = ieee80211_hw_config(local); |
@@ -545,8 +545,10 @@ static int ieee80211_ioctl_giwscan(struct net_device *dev, | |||
545 | { | 545 | { |
546 | int res; | 546 | int res; |
547 | struct ieee80211_local *local = wdev_priv(dev->ieee80211_ptr); | 547 | struct ieee80211_local *local = wdev_priv(dev->ieee80211_ptr); |
548 | if (local->sta_scanning) | 548 | |
549 | if (local->sta_sw_scanning || local->sta_hw_scanning) | ||
549 | return -EAGAIN; | 550 | return -EAGAIN; |
551 | |||
550 | res = ieee80211_sta_scan_results(dev, extra, data->length); | 552 | res = ieee80211_sta_scan_results(dev, extra, data->length); |
551 | if (res >= 0) { | 553 | if (res >= 0) { |
552 | data->length = res; | 554 | data->length = res; |