aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJouni Malinen <j@w1.fi>2011-11-19 19:15:10 +0200
committerJouni Malinen <j@w1.fi>2011-11-19 19:15:10 +0200
commit9dbf53fe35817a5af205f8cfc144d6de995bec37 (patch)
treee782f45c934a5552adbcbc6c93c65649c00977b2
parent9a898ee8796eb61650af9c7f4960e0c56317e1e4 (diff)
downloadexternal_wpa_supplicant_8_ti-9dbf53fe35817a5af205f8cfc144d6de995bec37.zip
external_wpa_supplicant_8_ti-9dbf53fe35817a5af205f8cfc144d6de995bec37.tar.gz
external_wpa_supplicant_8_ti-9dbf53fe35817a5af205f8cfc144d6de995bec37.tar.bz2
P2P: Send Listen state Probe Response frames without retries
Use the no-ACK send_mlme request to transmit Probe Response frames in P2P Listen state. This reduces number of unnecessary transmissions if the peer device has already moved away from the channel. It will most likely go through Search state multiple times anyway, so even if the response were to be lost, a new retry will happen at higher layer. Signed-hostap: Jouni Malinen <j@w1.fi>
-rw-r--r--wpa_supplicant/driver_i.h4
-rw-r--r--wpa_supplicant/p2p_supplicant.c2
2 files changed, 3 insertions, 3 deletions
diff --git a/wpa_supplicant/driver_i.h b/wpa_supplicant/driver_i.h
index 847bf80..8b584db 100644
--- a/wpa_supplicant/driver_i.h
+++ b/wpa_supplicant/driver_i.h
@@ -262,11 +262,11 @@ static inline int wpa_drv_set_country(struct wpa_supplicant *wpa_s,
}
static inline int wpa_drv_send_mlme(struct wpa_supplicant *wpa_s,
- const u8 *data, size_t data_len)
+ const u8 *data, size_t data_len, int noack)
{
if (wpa_s->driver->send_mlme)
return wpa_s->driver->send_mlme(wpa_s->drv_priv,
- data, data_len, 0);
+ data, data_len, noack);
return -1;
}
diff --git a/wpa_supplicant/p2p_supplicant.c b/wpa_supplicant/p2p_supplicant.c
index 9cb385f..c6484af 100644
--- a/wpa_supplicant/p2p_supplicant.c
+++ b/wpa_supplicant/p2p_supplicant.c
@@ -1045,7 +1045,7 @@ static void wpas_stop_listen(void *ctx)
static int wpas_send_probe_resp(void *ctx, const struct wpabuf *buf)
{
struct wpa_supplicant *wpa_s = ctx;
- return wpa_drv_send_mlme(wpa_s, wpabuf_head(buf), wpabuf_len(buf));
+ return wpa_drv_send_mlme(wpa_s, wpabuf_head(buf), wpabuf_len(buf), 1);
}