aboutsummaryrefslogtreecommitdiffstats
path: root/src/ap/ieee802_11.c
diff options
context:
space:
mode:
authorAyala Beker <ayala.beker@intel.com>2016-04-07 10:31:01 (GMT)
committerJouni Malinen <j@w1.fi>2016-04-08 10:02:49 (GMT)
commitae33239c555313e547b9a2a376c927ec50e2b9de (patch)
tree6c4f69d3a9b0bfa4d39b7e6f445a8eb0c47c3a2e /src/ap/ieee802_11.c
parent7405bb06ca29f8d06d105d49d2475b11be1f00eb (diff)
downloadhostap-ae33239c555313e547b9a2a376c927ec50e2b9de.zip
hostap-ae33239c555313e547b9a2a376c927ec50e2b9de.tar.gz
hostap-ae33239c555313e547b9a2a376c927ec50e2b9de.tar.bz2
AP: Pass station P2P PS capabilities info during station add/set
If a legacy client with no P2P PS support is trying to connect to a P2P GO, the driver should know that, and change its PS behavior accordingly. Add a parameter to hostapd_sta_add_params() indicating if P2P PS is supported by the station and pass this parameter to kernel with nl80211 driver when the station is added/set. Signed-off-by: Ayala Beker <ayala.beker@intel.com>
Diffstat (limited to 'src/ap/ieee802_11.c')
-rw-r--r--src/ap/ieee802_11.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/ap/ieee802_11.c b/src/ap/ieee802_11.c
index 6a373c5..aa2b965 100644
--- a/src/ap/ieee802_11.c
+++ b/src/ap/ieee802_11.c
@@ -1221,7 +1221,7 @@ static void handle_auth(struct hostapd_data *hapd,
WLAN_STA_AUTHORIZED);
if (hostapd_sta_add(hapd, sta->addr, 0, 0, 0, 0, 0,
- NULL, NULL, sta->flags, 0, 0, 0)) {
+ NULL, NULL, sta->flags, 0, 0, 0, 0)) {
hostapd_logger(hapd, sta->addr,
HOSTAPD_MODULE_IEEE80211,
HOSTAPD_LEVEL_NOTICE,
@@ -1805,7 +1805,8 @@ static int add_associated_sta(struct hostapd_data *hapd,
sta->flags & WLAN_STA_HT ? &ht_cap : NULL,
sta->flags & WLAN_STA_VHT ? &vht_cap : NULL,
sta->flags | WLAN_STA_ASSOC, sta->qosinfo,
- sta->vht_opmode, sta->added_unassoc)) {
+ sta->vht_opmode, sta->p2p_ie ? 1 : 0,
+ sta->added_unassoc)) {
hostapd_logger(hapd, sta->addr,
HOSTAPD_MODULE_IEEE80211, HOSTAPD_LEVEL_NOTICE,
"Could not %s STA to kernel driver",