diff options
| author | Tushnim Bhattacharyya <tushnimb@qca.qualcomm.com> | 2014-01-26 20:13:04 -0800 |
|---|---|---|
| committer | Prakash Dhavali <pdhavali@qca.qualcomm.com> | 2014-01-31 17:28:02 -0800 |
| commit | 07c450270c08fe4403644e7d5545edb70104f8ed (patch) | |
| tree | 8625ffba4049342f423f4aa3b7c3f7902ee20b98 | |
| parent | 785dcb9652e5dcc7ca2926bc65062a8ee16db4f2 (diff) | |
wlan-cld: hdd: Log the packet information in kmsg
Printing the packet information for tx/rx mgmt, action, EAPOL
and DHCP for debugging the connection issues.
A new ini variable is "gEnableDebugLog" added to
enable/disable these logs. By default this flag is disabled.
Also added an iwpriv command "setDbgLvl" to achieve the same.
Change-Id: Ia2e0fe372d267b83596be007ffd9c7b8407dbe56
CRs-Fixed: 600142
| -rw-r--r-- | CORE/HDD/inc/wlan_hdd_cfg.h | 13 | ||||
| -rw-r--r-- | CORE/HDD/src/wlan_hdd_cfg.c | 7 | ||||
| -rw-r--r-- | CORE/HDD/src/wlan_hdd_wext.c | 13 |
3 files changed, 33 insertions, 0 deletions
diff --git a/CORE/HDD/inc/wlan_hdd_cfg.h b/CORE/HDD/inc/wlan_hdd_cfg.h index 2137fbd00d72..a8125a7a5003 100644 --- a/CORE/HDD/inc/wlan_hdd_cfg.h +++ b/CORE/HDD/inc/wlan_hdd_cfg.h @@ -2192,6 +2192,18 @@ This feature requires the dependent cfg.ini "gRoamPrefer5GHz" set to 1 */ #define CFG_SAP_MAX_NO_PEERS_MAX (32) #define CFG_SAP_MAX_NO_PEERS_DEFAULT (32) +/* + * Connection related log Enable/Disable. + * 0x1 - Enable mgmt pkt logs (no probe req/rsp). + * 0x2 - Enable EAPOL pkt logs. + * 0x4 - Enable DHCP pkt logs. + * 0x0 - Disable all the above connection related logs. + */ +#define CFG_ENABLE_DEBUG_CONNECT_ISSUE "gEnableDebugLog" +#define CFG_ENABLE_DEBUG_CONNECT_ISSUE_MIN (0) +#define CFG_ENABLE_DEBUG_CONNECT_ISSUE_MAX (0xFF) +#define CFG_ENABLE_DEBUG_CONNECT_ISSUE_DEFAULT (0) + /*--------------------------------------------------------------------------- Type declarations -------------------------------------------------------------------------*/ @@ -2649,6 +2661,7 @@ typedef struct v_U16_t thermalTempMinLevel3; v_U16_t thermalTempMaxLevel3; #endif + v_U32_t gEnableDebugLog; } 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 943d40c3a808..22e1f21fc55c 100644 --- a/CORE/HDD/src/wlan_hdd_cfg.c +++ b/CORE/HDD/src/wlan_hdd_cfg.c @@ -3078,6 +3078,12 @@ REG_VARIABLE( CFG_SAP_MAX_NO_PEERS, WLAN_PARAM_Integer, CFG_THERMAL_TEMP_MAX_LEVEL3_MIN, CFG_THERMAL_TEMP_MAX_LEVEL3_MAX ), #endif /*#ifndef QCA_WIFI_ISOC*/ + REG_VARIABLE( CFG_ENABLE_DEBUG_CONNECT_ISSUE, WLAN_PARAM_Integer, + hdd_config_t, gEnableDebugLog, + VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT, + CFG_ENABLE_DEBUG_CONNECT_ISSUE_DEFAULT, + CFG_ENABLE_DEBUG_CONNECT_ISSUE_MIN , + CFG_ENABLE_DEBUG_CONNECT_ISSUE_MAX), }; /* @@ -5054,6 +5060,7 @@ VOS_STATUS hdd_set_sme_config( hdd_context_t *pHddCtx ) smeConfig.pnoOffload = pHddCtx->cfg_ini->PnoOffload; #endif + smeConfig.fEnableDebugLog = pHddCtx->cfg_ini->gEnableDebugLog; halStatus = sme_UpdateConfig( pHddCtx->hHal, &smeConfig); if ( !HAL_STATUS_SUCCESS( halStatus ) ) { diff --git a/CORE/HDD/src/wlan_hdd_wext.c b/CORE/HDD/src/wlan_hdd_wext.c index 6cfbe2a4db48..bde8b54d28ce 100644 --- a/CORE/HDD/src/wlan_hdd_wext.c +++ b/CORE/HDD/src/wlan_hdd_wext.c @@ -224,6 +224,8 @@ static const hdd_freq_chan_map_t freq_chan_map[] = { {2412, 1}, {2417, 2}, /* Private ioctl to configure MCC home channels time quota and latency */ #define WE_MCC_CONFIG_LATENCY 70 #define WE_MCC_CONFIG_QUOTA 71 +/* Private IOCTL for debug connection issues */ +#define WE_SET_DEBUG_LOG 72 /* Private ioctls and their sub-ioctls */ #define WLAN_PRIV_SET_NONE_GET_INT (SIOCIWFIRSTPRIV + 1) @@ -5498,6 +5500,13 @@ static int iw_setint_getnone(struct net_device *dev, struct iw_request_info *inf } break; } + case WE_SET_DEBUG_LOG: + { + hdd_context_t *pHddCtx = WLAN_HDD_GET_CTX(pAdapter); + pHddCtx->cfg_ini->gEnableDebugLog = set_value; + sme_UpdateConnectDebug(pHddCtx->hHal, set_value); + break; + } #endif default: @@ -9725,6 +9734,10 @@ static const struct iw_priv_args we_private_args[] = { IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "setMccQuota" }, + { WE_SET_DEBUG_LOG, + IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, + 0, "setDbgLvl" }, + #endif { WLAN_PRIV_SET_NONE_GET_INT, |
