Skip to content

Commit

Permalink
mac80211: fix idle handling in monitor mode
Browse files Browse the repository at this point in the history
When the driver does not want a monitor mode VIF, no channel context is
allocated for it. This causes ieee80211_recalc_idle to put the hardware
into idle mode if only a monitor mode is active, breaking injection.

Fix this by checking local->monitors in addition to active channel
contexts.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
  • Loading branch information
Felix Fietkau authored and jmberg-intel committed Feb 26, 2013
1 parent a7679ed commit b759f4d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/mac80211/iface.c
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ void ieee80211_recalc_idle(struct ieee80211_local *local)

lockdep_assert_held(&local->mtx);

active = !list_empty(&local->chanctx_list);
active = !list_empty(&local->chanctx_list) || local->monitors;

if (!local->ops->remain_on_channel) {
list_for_each_entry(roc, &local->roc_list, list) {
Expand Down

0 comments on commit b759f4d

Please sign in to comment.