ソースを参照

qcacld-3.0: Update uninitialized variables & error handling

Currently, In failure case the spin unlock is not taken care
which is locked before, also the variables are initailized in
specific senarios, with this change the variables are initialised
properly.

Change-Id: Ic6c40065e312dcd2e76dbf50304dfa8f4fb506e9
CRs-Fixed: 1073567
Anurag Chouhan 8 年 前
コミット
00ed527a14
2 ファイル変更2 行追加2 行削除
  1. 1 1
      core/hdd/src/wlan_hdd_cfg80211.c
  2. 1 1
      core/hdd/src/wlan_hdd_napi.c

+ 1 - 1
core/hdd/src/wlan_hdd_cfg80211.c

@@ -14461,7 +14461,7 @@ __wlan_hdd_cfg80211_set_ap_channel_width(struct wiphy *wiphy,
 	hdd_context_t *pHddCtx;
 	QDF_STATUS status;
 	tSmeConfigParams sme_config;
-	bool cbModeChange;
+	bool cbModeChange = false;
 
 	if (QDF_GLOBAL_FTM_MODE == hdd_get_conparam()) {
 		hdd_err("Command not allowed in FTM mode");

+ 1 - 1
core/hdd/src/wlan_hdd_napi.c

@@ -275,7 +275,7 @@ int hdd_napi_apply_throughput_policy(struct hdd_context_s *hddctx,
 	uint64_t packets = tx_packets + rx_packets;
 	enum qca_napi_tput_state req_state;
 	struct qca_napi_data *napid = hdd_napi_get_all();
-	int    enabled;
+	int enabled = 0;
 
 	NAPI_DEBUG("-->%s(tx=%lld, rx=%lld)", __func__, tx_packets, rx_packets);