qcacld-3.0: Featurize BUILD_DIAG_VERSION

Featurize BUILD_DIAG_VERSION to compile out to save memory.

Change-Id: Ib6b6c8d197556a9457e600dd5e802f7e50f6242d
CRs-Fixed: 2301487
This commit is contained in:
Qiwei Cai 2018-08-23 10:43:16 +08:00 committed by nshrivas
parent 04037a171f
commit ba95ce632f
7 changed files with 9 additions and 11 deletions

2
Kbuild
View File

@ -1623,9 +1623,7 @@ ifeq ($(CONFIG_REMOVE_PKT_LOG), n)
INCS += $(PKTLOG_INC)
endif
ifeq ($(BUILD_DIAG_VERSION), y)
INCS += $(HOST_DIAG_LOG_INC)
endif
INCS += $(DISA_INC)
INCS += $(ACTION_OUI_INC)

View File

@ -60,7 +60,7 @@ endif
# Debug specific features
CONFIG_WLAN_LOGGING_BUFFERS_DYNAMICALLY := y
BUILD_DEBUG_VERSION := y
BUILD_DIAG_VERSION := y
BUILD_DIAG_VERSION := n
CONFIG_REMOVE_PKT_LOG := n
CONFIG_FEATURE_HTC_CREDIT_HISTORY := y

View File

@ -422,6 +422,7 @@ uint32_t hdd_txrx_get_tx_ack_count(struct hdd_adapter *adapter)
adapter->session_id);
}
#ifdef FEATURE_WLAN_DIAG_SUPPORT
/**
* qdf_event_eapol_log() - send event to wlan diag
* @skb: skb ptr
@ -463,7 +464,7 @@ void hdd_event_eapol_log(struct sk_buff *skb, enum qdf_proto_dir dir)
WLAN_HOST_DIAG_EVENT_REPORT(&wlan_diag_event, EVENT_WLAN_EAPOL);
}
#endif /* FEATURE_WLAN_DIAG_SUPPORT */
/**
* wlan_hdd_classify_pkt() - classify packet

View File

@ -708,9 +708,11 @@ void lim_diag_mgmt_rx_event_report(tpAniSirGlobal mac_ctx, void *mgmt_hdr,
static inline void lim_diag_event_report(tpAniSirGlobal pMac, uint16_t
eventType, tpPESession pSessionEntry, uint16_t status,
uint16_t reasonCode) {}
static inline
void lim_diag_mgmt_tx_event_report(tpAniSirGlobal mac_ctx, void *mgmt_hdr,
tpPESession session, uint16_t result_code,
uint16_t reason_code) {}
static inline
void lim_diag_mgmt_rx_event_report(tpAniSirGlobal mac_ctx, void *mgmt_hdr,
tpPESession session, uint16_t result_code,
uint16_t reason_code) {}

View File

@ -200,7 +200,6 @@ enum csr_roam_stats_classtypes {
eCsrMaxStats
};
#ifdef FEATURE_WLAN_DIAG_SUPPORT
enum csr_diagwlan_status_eventsubtype {
eCSR_WLAN_STATUS_CONNECT = 0,
eCSR_WLAN_STATUS_DISCONNECT
@ -216,11 +215,8 @@ enum csr_diagwlan_status_eventreason {
eCSR_REASON_ROAM_SYNCH_IND,
eCSR_REASON_ROAM_SYNCH_CNF,
eCSR_REASON_ROAM_HO_FAIL,
};
#endif /* FEATURE_WLAN_DIAG_SUPPORT */
struct csr_channel {
uint8_t numChannels;
uint8_t channelList[WNI_CFG_VALID_CHANNEL_LIST_LEN];

View File

@ -7330,7 +7330,6 @@ static void csr_roam_process_start_bss_success(tpAniSirGlobal mac_ctx,
tSirMacAddr bcast_mac = { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff };
QDF_STATUS status;
host_log_ibss_pkt_type *ibss_log;
uint32_t bi;
#ifdef FEATURE_WLAN_MCC_TO_SCC_SWITCH
tSirSmeHTProfile *src_profile = NULL;
tCsrRoamHTProfile *dst_profile = NULL;
@ -7404,6 +7403,7 @@ static void csr_roam_process_start_bss_success(tpAniSirGlobal mac_ctx,
WLAN_HOST_DIAG_LOG_ALLOC(ibss_log,
host_log_ibss_pkt_type, LOG_WLAN_IBSS_C);
if (ibss_log) {
uint32_t bi;
if (CSR_INVALID_SCANRESULT_HANDLE ==
cmd->u.roamCmd.hBSSList) {
/*
@ -7431,6 +7431,7 @@ static void csr_roam_process_start_bss_success(tpAniSirGlobal mac_ctx,
WLAN_HOST_DIAG_LOG_REPORT(ibss_log);
}
#endif
ibss_log = NULL;
/*
* Only set context for non-WDS_STA. We don't even need it for
* WDS_AP. But since the encryption.
@ -8135,6 +8136,7 @@ static bool csr_roam_process_results(tpAniSirGlobal mac_ctx, tSmeCmd *cmd,
WLAN_HOST_DIAG_LOG_REPORT(ibss_log);
}
#endif
ibss_log = NULL;
start_bss_rsp = (tSirSmeStartBssRsp *)context;
qdf_mem_set(&roam_info, sizeof(roam_info), 0);
roam_status = eCSR_ROAM_IBSS_IND;

View File

@ -770,6 +770,7 @@ void csr_clear_votes_for_country_info(tpAniSirGlobal pMac)
sizeof(struct csr_votes11d) * CSR_MAX_NUM_COUNTRY_CODE, 0);
}
#ifdef FEATURE_WLAN_DIAG_SUPPORT_CSR
/* caller allocated memory for pNumChn and pChnPowerInfo */
/* As input, *pNumChn has the size of the array of pChnPowerInfo */
/* Upon return, *pNumChn has the number of channels assigned. */
@ -796,10 +797,8 @@ static void csr_get_channel_power_info(tpAniSirGlobal pMac, tDblLinkList *list,
entry = csr_ll_next(list, entry, LL_ACCESS_LOCK);
}
*num_ch = chn_idx;
}
#ifdef FEATURE_WLAN_DIAG_SUPPORT_CSR
static void csr_diag_apply_country_info(tpAniSirGlobal mac_ctx)
{
host_log_802_11d_pkt_type *p11dLog;