mac80211: only warn once on chanctx_conf being NULL
[linux-2.6-block.git] / net / mac80211 / ieee80211_i.h
index a8af4aafa1171798151e5ced1f9f91ffd9a149e2..682d0ab1bf899976b745e078203fa4ec21103f72 100644 (file)
@@ -1435,7 +1435,7 @@ ieee80211_get_sband(struct ieee80211_sub_if_data *sdata)
        rcu_read_lock();
        chanctx_conf = rcu_dereference(sdata->vif.chanctx_conf);
 
-       if (WARN_ON(!chanctx_conf)) {
+       if (WARN_ON_ONCE(!chanctx_conf)) {
                rcu_read_unlock();
                return NULL;
        }