From 970fa12ea2c1b99a8e7fbfc12a97393b5727361e Mon Sep 17 00:00:00 2001 From: Rajkumar Manoharan Date: Sat, 29 Oct 2011 21:23:27 +0300 Subject: [PATCH] nl80211: Add support to disable CCK rate for P2P frames Add a new attribute to specify whether to use CCK rate or not during scan and sending management frames. This helps to send P2P probes at non-CCK rate. This ensures that P2P probe request/response/action frames are always sent at non-CCK rates. Signed-off-by: Rajkumar Manoharan --- src/drivers/driver_nl80211.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/drivers/driver_nl80211.c b/src/drivers/driver_nl80211.c index ed9681cb9..de9d532d0 100644 --- a/src/drivers/driver_nl80211.c +++ b/src/drivers/driver_nl80211.c @@ -2612,6 +2612,8 @@ static int wpa_driver_nl80211_scan(void *priv, NLA_PUT(rates, NL80211_BAND_2GHZ, 8, "\x0c\x12\x18\x24\x30\x48\x60\x6c"); nla_put_nested(msg, NL80211_ATTR_SCAN_SUPP_RATES, rates); + + NLA_PUT_FLAG(msg, NL80211_ATTR_TX_NO_CCK_RATE); } ret = send_and_recv_msgs(drv, msg, NULL, NULL); @@ -6758,6 +6760,8 @@ static int nl80211_send_frame_cmd(struct wpa_driver_nl80211_data *drv, if (wait) NLA_PUT_U32(msg, NL80211_ATTR_DURATION, wait); NLA_PUT_FLAG(msg, NL80211_ATTR_OFFCHANNEL_TX_OK); + NLA_PUT_FLAG(msg, NL80211_ATTR_TX_NO_CCK_RATE); + NLA_PUT(msg, NL80211_ATTR_FRAME, buf_len, buf); cookie = 0;