IEEE80211_PARSE_ERR_DUP_ELEM = BIT(1),
IEEE80211_PARSE_ERR_BAD_ELEM_SIZE = BIT(2),
IEEE80211_PARSE_ERR_UNEXPECTED_ELEM = BIT(3),
+ IEEE80211_PARSE_ERR_DUP_NEST_ML_BASIC = BIT(4),
};
/* Parsed Information Elements */
link->u.mgd.bss_param_ch_cnt =
ieee80211_mle_get_bss_param_ch_cnt(elems->ml_basic);
}
- } else if (!elems->prof ||
+ } else if (elems->parse_error & IEEE80211_PARSE_ERR_DUP_NEST_ML_BASIC ||
+ !elems->prof ||
!(elems->prof->control & prof_bss_param_ch_present)) {
ret = false;
goto out;
switch (le16_get_bits(mle->control,
IEEE80211_ML_CONTROL_TYPE)) {
case IEEE80211_ML_CONTROL_TYPE_BASIC:
+ if (elems->ml_basic) {
+ elems->parse_error |=
+ IEEE80211_PARSE_ERR_DUP_NEST_ML_BASIC;
+ break;
+ }
elems->ml_basic_elem = (void *)elem;
elems->ml_basic = data;
elems->ml_basic_len = len;