@@ -502,7 +502,8 @@ int nl80211_parse_chandef(struct l_genl_msg *msg, struct band_chandef *out)
int nl80211_parse_supported_frequencies(struct l_genl_attr *band_freqs,
struct scan_freq_set *supported_list,
- struct scan_freq_set *disabled_list)
+ struct scan_freq_set *disabled_list,
+ struct scan_freq_set *no_ir_list)
{
uint16_t type, len;
const void *data;
@@ -515,6 +516,7 @@ int nl80211_parse_supported_frequencies(struct l_genl_attr *band_freqs,
while (l_genl_attr_next(&nested, NULL, NULL, NULL)) {
uint32_t freq = 0;
bool disabled = false;
+ bool no_ir = false;
if (!l_genl_attr_recurse(&nested, &attr))
continue;
@@ -527,6 +529,9 @@ int nl80211_parse_supported_frequencies(struct l_genl_attr *band_freqs,
case NL80211_FREQUENCY_ATTR_DISABLED:
disabled = true;
break;
+ case NL80211_FREQUENCY_ATTR_NO_IR:
+ no_ir = true;
+ break;
}
}
@@ -538,6 +543,10 @@ int nl80211_parse_supported_frequencies(struct l_genl_attr *band_freqs,
if (disabled && disabled_list)
scan_freq_set_add(disabled_list, freq);
+
+ if (no_ir && no_ir_list)
+ scan_freq_set_add(no_ir_list, freq);
+
}
return 0;
@@ -59,4 +59,5 @@ struct l_genl_msg *nl80211_build_cmd_frame(uint32_t ifindex,
int nl80211_parse_chandef(struct l_genl_msg *msg, struct band_chandef *out);
int nl80211_parse_supported_frequencies(struct l_genl_attr *band_freqs,
struct scan_freq_set *supported,
- struct scan_freq_set *disabled);
+ struct scan_freq_set *disabled,
+ struct scan_freq_set *no_ir);
@@ -1514,7 +1514,8 @@ static void parse_supported_bands(struct wiphy *wiphy,
case NL80211_BAND_ATTR_FREQS:
nl80211_parse_supported_frequencies(&attr,
wiphy->supported_freqs,
- wiphy->disabled_freqs);
+ wiphy->disabled_freqs,
+ NULL);
break;
case NL80211_BAND_ATTR_RATES:
@@ -1988,7 +1989,8 @@ static void wiphy_dump_callback(struct l_genl_msg *msg,
continue;
nl80211_parse_supported_frequencies(&attr, NULL,
- wiphy->pending_freqs);
+ wiphy->pending_freqs,
+ NULL);
}
}
}