nl80211: Add support for sta_add flags_mask

Signed-off-by: Javier Lopez <jlopex@gmail.com>
Signed-off-by: Javier Cardona <javier@cozybit.com>
Signed-off-by: Jason Mobarak <x@jason.mobarak.name>
Signed-off-by: Bob Copeland <me@bobcopeland.com>
This commit is contained in:
Bob Copeland 2014-09-01 00:23:23 -04:00 committed by Jouni Malinen
parent 6c1664f605
commit 7e31703e4d
2 changed files with 3 additions and 2 deletions

View File

@ -1124,6 +1124,7 @@ struct hostapd_sta_add_params {
int vht_opmode_enabled;
u8 vht_opmode;
u32 flags; /* bitmask of WPA_STA_* flags */
u32 flags_mask; /* unset bits in flags */
int set; /* Set STA parameters instead of add */
u8 qosinfo;
const u8 *ext_capab;

View File

@ -7764,8 +7764,8 @@ static int wpa_driver_nl80211_sta_add(void *priv,
}
os_memset(&upd, 0, sizeof(upd));
upd.mask = sta_flags_nl80211(params->flags);
upd.set = upd.mask;
upd.set = sta_flags_nl80211(params->flags);
upd.mask = upd.set | sta_flags_nl80211(params->flags_mask);
wpa_printf(MSG_DEBUG, " * flags set=0x%x mask=0x%x",
upd.set, upd.mask);
NLA_PUT(msg, NL80211_ATTR_STA_FLAGS2, sizeof(upd), &upd);