Configure flag to debug remain on channel issues.
Add flag to configuration file to debug remain on
channel. This flag is used to send marker frames
at start and end of remain on channel.
Change-Id: I0a61e205144004617b0b21551e174c424323cece
CRs-Fixed: 594906
diff --git a/CORE/HDD/inc/wlan_hdd_cfg.h b/CORE/HDD/inc/wlan_hdd_cfg.h
index ea60fe0..b2ed5d6 100644
--- a/CORE/HDD/inc/wlan_hdd_cfg.h
+++ b/CORE/HDD/inc/wlan_hdd_cfg.h
@@ -1984,6 +1984,12 @@
#define CFG_OVERRIDE_COUNTRY_CODE "gStaCountryCode"
#define CFG_OVERRIDE_COUNTRY_CODE_DEFAULT "000"
+//Enable debug for remain on channel issues
+#define CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_NAME "gDebugP2pRemainOnChannel"
+#define CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_DEFAULT ( 0 )
+#define CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_MIN ( 0 )
+#define CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_MAX ( 1 )
+
/*---------------------------------------------------------------------------
Type declarations
-------------------------------------------------------------------------*/
@@ -2398,6 +2404,7 @@
v_BOOL_t IsMemoryDebugSupportEnabled;
#endif
char overrideCountryCode[4];
+ v_BOOL_t debugP2pRemainOnChannel;
} hdd_config_t;
/*---------------------------------------------------------------------------
Function declarations and documenation
diff --git a/CORE/HDD/src/wlan_hdd_cfg.c b/CORE/HDD/src/wlan_hdd_cfg.c
index 4995e20..4778003 100644
--- a/CORE/HDD/src/wlan_hdd_cfg.c
+++ b/CORE/HDD/src/wlan_hdd_cfg.c
@@ -2836,6 +2836,13 @@
hdd_config_t, overrideCountryCode,
VAR_FLAGS_OPTIONAL,
(void *)CFG_OVERRIDE_COUNTRY_CODE_DEFAULT),
+
+ REG_VARIABLE( CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_NAME, WLAN_PARAM_Integer,
+ hdd_config_t, debugP2pRemainOnChannel,
+ VAR_FLAGS_OPTIONAL,
+ CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_DEFAULT,
+ CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_MIN,
+ CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_MAX ),
};
/*
@@ -4459,6 +4466,16 @@
fStatus = FALSE;
hddLog(LOGE, "Could not pass on WNI_BTC_ACTIVE_BT_LEN to CCM");
}
+
+ if (ccmCfgSetInt(pHddCtx->hHal,
+ WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL,
+ pConfig->debugP2pRemainOnChannel,
+ NULL, eANI_BOOLEAN_FALSE) == eHAL_STATUS_FAILURE)
+ {
+ fStatus = FALSE;
+ hddLog(LOGE,
+ "Could not pass on WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL to CCM");
+ }
return fStatus;
}
diff --git a/CORE/MAC/inc/wniCfgAp.h b/CORE/MAC/inc/wniCfgAp.h
index bfe9455..b22bcbe 100644
--- a/CORE/MAC/inc/wniCfgAp.h
+++ b/CORE/MAC/inc/wniCfgAp.h
@@ -369,6 +369,7 @@
#define WNI_CFG_BTC_ACTIVE_BT_LEN 308
#define WNI_CFG_BTC_SAP_ACTIVE_WLAN_LEN 309
#define WNI_CFG_BTC_SAP_ACTIVE_BT_LEN 310
+#define WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL 311
/*
* String parameter lengths
@@ -2608,10 +2609,18 @@
#define WNI_CFG_BTC_SAP_ACTIVE_BT_LEN_APMAX 250000
#define WNI_CFG_BTC_SAP_ACTIVE_BT_LEN_APDEF 90000
-#define CFG_PARAM_MAX_NUM 311
-#define CFG_AP_IBUF_MAX_SIZE 250
+#define WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_STAMIN 0
+#define WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_STAMAX 1
+#define WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_STADEF 0
+
+#define WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_APMIN 0
+#define WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_APMAX 1
+#define WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_APDEF 0
+
+#define CFG_PARAM_MAX_NUM 312
+#define CFG_AP_IBUF_MAX_SIZE 251
#define CFG_AP_SBUF_MAX_SIZE 3422
-#define CFG_STA_IBUF_MAX_SIZE 245
+#define CFG_STA_IBUF_MAX_SIZE 246
#define CFG_STA_SBUF_MAX_SIZE 3388
#define CFG_SEM_MAX_NUM 19
diff --git a/CORE/MAC/inc/wniCfgSta.h b/CORE/MAC/inc/wniCfgSta.h
index 13f9014..37c913b 100644
--- a/CORE/MAC/inc/wniCfgSta.h
+++ b/CORE/MAC/inc/wniCfgSta.h
@@ -363,6 +363,7 @@
#define WNI_CFG_BTC_ACTIVE_BT_LEN 308
#define WNI_CFG_BTC_SAP_ACTIVE_WLAN_LEN 309
#define WNI_CFG_BTC_SAP_ACTIVE_BT_LEN 310
+#define WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL 311
/*
* String parameter lengths
@@ -1689,8 +1690,12 @@
#define WNI_CFG_BTC_SAP_ACTIVE_BT_LEN_STAMAX 250000
#define WNI_CFG_BTC_SAP_ACTIVE_BT_LEN_STADEF 90000
-#define CFG_PARAM_MAX_NUM 311
-#define CFG_STA_IBUF_MAX_SIZE 245
+#define WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_STAMIN 0
+#define WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_STAMAX 1
+#define WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL_STADEF 0
+
+#define CFG_PARAM_MAX_NUM 312
+#define CFG_STA_IBUF_MAX_SIZE 246
#define CFG_STA_SBUF_MAX_SIZE 3388
#define CFG_SEM_MAX_NUM 19
diff --git a/CORE/MAC/src/cfg/cfgParamName.c b/CORE/MAC/src/cfg/cfgParamName.c
index 487269c..26fa0ea 100644
--- a/CORE/MAC/src/cfg/cfgParamName.c
+++ b/CORE/MAC/src/cfg/cfgParamName.c
@@ -340,7 +340,7 @@
(unsigned char *)"BTC_ACTIVE_BT_LEN",
(unsigned char *)"BTC_SAP_ACTIVE_WLAN_LEN",
(unsigned char *)"BTC_SAP_ACTIVE_BT_LEN",
+ (unsigned char *)"DEBUG_P2P_REMAIN_ON_CHANNEL",
};
-
diff --git a/CORE/MAC/src/cfg/cfgUtil/cfg.txt b/CORE/MAC/src/cfg/cfgUtil/cfg.txt
index 4fe2fb5..7b65765 100644
--- a/CORE/MAC/src/cfg/cfgUtil/cfg.txt
+++ b/CORE/MAC/src/cfg/cfgUtil/cfg.txt
@@ -4649,3 +4649,16 @@
0 250000 90000
*
*
+
+* Debug p2p remain on channel
+*
+WNI_CFG_DEBUG_P2P_REMAIN_ON_CHANNEL I 4 7
+V RW NP
+NONE
+0 1 0
+V RW NP
+NONE
+0 1 0
+*
+*
+
diff --git a/firmware_bin/WCNSS_cfg.dat b/firmware_bin/WCNSS_cfg.dat
index 5685e79..764a7e0 100644
--- a/firmware_bin/WCNSS_cfg.dat
+++ b/firmware_bin/WCNSS_cfg.dat
Binary files differ