]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
P2P: Enable U-APSD support on GO automatically
authorJouni Malinen <jouni@qca.qualcomm.com>
Mon, 17 Feb 2014 11:15:29 +0000 (13:15 +0200)
committerJouni Malinen <j@w1.fi>
Mon, 17 Feb 2014 11:15:29 +0000 (13:15 +0200)
Since P2P specification mandates P2P GO to support WMM-PS with legacy
STAs, enable this automatically if the driver indicates support for
U-APSD in AP mode. The "P2P_SET go_apsd 0" command can still be used to
disable this if needed.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
wpa_supplicant/ap.c

index 4ff27d6c99933bd831dc96a6c023efb4ce9bc08a..f150679e77744514d02d109c7394e5be54712ca1 100644 (file)
@@ -542,6 +542,8 @@ int wpa_supplicant_create_ap(struct wpa_supplicant *wpa_s,
 
        if (wpa_s->parent->set_ap_uapsd)
                params.uapsd = wpa_s->parent->ap_uapsd;
+       else if (params.p2p && (wpa_s->drv_flags & WPA_DRIVER_FLAGS_AP_UAPSD))
+               params.uapsd = 1; /* mandatory for P2P GO */
        else
                params.uapsd = -1;