Bladeren bron

qcacld-3.0: Fix HDD logging API in wlan_hdd_p2p (phase 2)

Previously "qcacld-3.0: Fix HDD logging API in wlan_hdd_p2p" fixed all
instances of legacy logging APIs in wlan_hdd_p2p.c. Unfortunately
since that time new instances of legacy logging APIs were added. Fix
those instances, and enable the compiler macro which will prevent new
instances from being added in the future.

Change-Id: Iaf9dc9a11943ec918a51aa8c9b97a5a49fad535b
CRs-Fixed: 1097439
Jeff Johnson 8 jaren geleden
bovenliggende
commit
1a92f8cf5c
1 gewijzigde bestanden met toevoegingen van 11 en 10 verwijderingen
  1. 11 10
      core/hdd/src/wlan_hdd_p2p.c

+ 11 - 10
core/hdd/src/wlan_hdd_p2p.c

@@ -33,6 +33,9 @@
  *
  */
 
+/* denote that this file does not allow legacy hddLog */
+#define HDD_DISALLOW_LEGACY_HDDLOG 1
+
 #include <wlan_hdd_includes.h>
 #include <wlan_hdd_hostapd.h>
 #include <net/cfg80211.h>
@@ -612,9 +615,8 @@ static int wlan_hdd_execute_remain_on_channel(hdd_adapter_t *pAdapter,
 			mutex_lock(&cfgState->remain_on_chan_ctx_lock);
 			pAdapter->is_roc_inprogress = false;
 			pRemainChanCtx = cfgState->remain_on_chan_ctx;
-			hddLog(LOG1,
-				FL("Freeing ROC ctx cfgState->remain_on_chan_ctx=%p"),
-				cfgState->remain_on_chan_ctx);
+			hdd_info("Freeing ROC ctx cfgState->remain_on_chan_ctx=%p",
+				 cfgState->remain_on_chan_ctx);
 			if (pRemainChanCtx) {
 				if (qdf_mc_timer_destroy(
 					&pRemainChanCtx->
@@ -654,9 +656,8 @@ static int wlan_hdd_execute_remain_on_channel(hdd_adapter_t *pAdapter,
 			mutex_lock(&cfgState->remain_on_chan_ctx_lock);
 			pAdapter->is_roc_inprogress = false;
 			pRemainChanCtx = cfgState->remain_on_chan_ctx;
-			hddLog(LOG1,
-				FL("Freeing ROC ctx cfgState->remain_on_chan_ctx=%p"),
-				cfgState->remain_on_chan_ctx);
+			hdd_info("Freeing ROC ctx cfgState->remain_on_chan_ctx=%p",
+				 cfgState->remain_on_chan_ctx);
 			if (pRemainChanCtx) {
 				if (qdf_mc_timer_destroy(
 					&pRemainChanCtx->
@@ -1457,8 +1458,8 @@ static int __wlan_hdd_mgmt_tx(struct wiphy *wiphy, struct wireless_dev *wdev,
 					 WLAN_HDD_INVITATION_RESP)
 					wait = wait + ACTION_FRAME_ACK_WAIT;
 
-				hddLog(LOG1, FL("Extending the wait time %d for actionFrmType=%d"),
-						wait, actionFrmType);
+				hdd_info("Extending the wait time %d for actionFrmType=%d",
+					 wait, actionFrmType);
 
 				if (qdf_mc_timer_stop(&cfgState->
 						remain_on_chan_ctx->
@@ -1755,12 +1756,12 @@ void hdd_send_action_cnf_cb(uint32_t session_id, bool tx_completed)
 
 	adapter = hdd_get_adapter_by_sme_session_id(hdd_ctx, session_id);
 	if (NULL == adapter) {
-		hddLog(LOGE, FL("adapter not found"));
+		hdd_err("adapter not found");
 		return;
 	}
 
 	if (WLAN_HDD_ADAPTER_MAGIC != adapter->magic) {
-		hddLog(LOGE, FL("adapter has invalid magic"));
+		hdd_err("adapter has invalid magic");
 		return;
 	}