From 350fb12d61f64e8722cfaeef113f54cb43dfbfb4 Mon Sep 17 00:00:00 2001 From: Ahmad Kholaif Date: Fri, 14 Mar 2014 18:35:37 -0700 Subject: qca_cld: fix the action frame sub type offset value for Remain-on-Channel In hdd_p2p_is_action_type_rsp(), the input buffer is starting from public action type offset, i.e., buf[24]. However, we were double advancing the buffer within the function. As a result, the frame type check within the function was always failing and Remain-On-Channel gets cancelled. This prevents the device from receiving action response frames. Change-Id: If033dc974a33f8be7a684f92f2fc681e1adc27af CRs-fixed: 626368 --- CORE/HDD/inc/wlan_hdd_main.h | 1 + CORE/HDD/src/wlan_hdd_p2p.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CORE/HDD/inc/wlan_hdd_main.h b/CORE/HDD/inc/wlan_hdd_main.h index 9c47f90bb47d..33b3c196c583 100644 --- a/CORE/HDD/inc/wlan_hdd_main.h +++ b/CORE/HDD/inc/wlan_hdd_main.h @@ -178,6 +178,7 @@ #define WLAN_HDD_WFA_P2P_OUI_TYPE 0x09 #define WLAN_HDD_P2P_SOCIAL_CHANNELS 3 #define WLAN_HDD_P2P_SINGLE_CHANNEL_SCAN 1 +#define WLAN_HDD_PUBLIC_ACTION_FRAME_SUB_TYPE_OFFSET 6 #define WLAN_HDD_IS_SOCIAL_CHANNEL(center_freq) \ (((center_freq) == 2412) || ((center_freq) == 2437) || ((center_freq) == 2462)) diff --git a/CORE/HDD/src/wlan_hdd_p2p.c b/CORE/HDD/src/wlan_hdd_p2p.c index a969e6d1763e..061a34806f6e 100644 --- a/CORE/HDD/src/wlan_hdd_p2p.c +++ b/CORE/HDD/src/wlan_hdd_p2p.c @@ -127,7 +127,7 @@ static bool hdd_p2p_is_action_type_rsp( const u8 *buf ) return FALSE; } - actionFrmType = buf[WLAN_HDD_PUBLIC_ACTION_FRAME_TYPE_OFFSET]; + actionFrmType = buf[WLAN_HDD_PUBLIC_ACTION_FRAME_SUB_TYPE_OFFSET]; if ( actionFrmType != WLAN_HDD_INVITATION_REQ && actionFrmType != WLAN_HDD_GO_NEG_REQ && actionFrmType != WLAN_HDD_DEV_DIS_REQ && -- cgit v1.2.3