Commit 8876c67e authored by Johannes Berg's avatar Johannes Berg

wifi: nl80211: require MLD address on link STA add/modify

We always need the MLD address and link ID to add or
modify the link STA, so require it in the API.

Fixes: 577e5b8c ("wifi: cfg80211: add API to add/modify/remove a link station")
Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
parent 956b9613
......@@ -15827,14 +15827,13 @@ nl80211_add_mod_link_station(struct sk_buff *skb, struct genl_info *info,
if (add && !info->attrs[NL80211_ATTR_MAC])
return -EINVAL;
if (add && !info->attrs[NL80211_ATTR_MLD_ADDR])
if (!info->attrs[NL80211_ATTR_MLD_ADDR])
return -EINVAL;
if (add && !info->attrs[NL80211_ATTR_STA_SUPPORTED_RATES])
return -EINVAL;
if (info->attrs[NL80211_ATTR_MLD_ADDR])
params.mld_mac = nla_data(info->attrs[NL80211_ATTR_MLD_ADDR]);
params.mld_mac = nla_data(info->attrs[NL80211_ATTR_MLD_ADDR]);
if (info->attrs[NL80211_ATTR_MAC]) {
params.link_mac = nla_data(info->attrs[NL80211_ATTR_MAC]);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment