qcacld-3.0: Validate if tlds is enabled before setting connection tracker

In the present scenario driver checks for  eTDLS_SUPPORT_DISABLED
before enabling the connection tracker for tdls mode. But if the
tdls is disabled from the ini or disabled in the firmware eTDLS_SUPPORT_NOT_ENABLED
is set in the tdls_mode. Checking for only eTDLS_SUPPORT_DISABLED is resulting
in enabling the connection tracker which tries to access the tdls_ctx
which is NULL.

To mitigate the issue also check for eTDLS_SUPPORT_NOT_ENABLED in the tdls_mode
before enabling the connection tracker.

CRs-Fixed: 1096830
Change-Id: I1e13af6b63aa058c19117efa99563540aa02da0b
This commit is contained in:
Arunk Khandavalli 2016-12-08 15:27:22 +05:30 committed by qcabuildsw
parent 9c25e91d4c
commit cfe32d1cd7

View File

@ -1648,6 +1648,7 @@ void cds_set_tdls_ct_mode(hdd_context_t *hdd_ctx)
}
if (eTDLS_SUPPORT_DISABLED == hdd_ctx->tdls_mode ||
eTDLS_SUPPORT_NOT_ENABLED == hdd_ctx->tdls_mode ||
(!hdd_ctx->config->fEnableTDLSImplicitTrigger)) {
state = false;
goto set_state;