Przeglądaj źródła

Merge "msm: ipa: Set the logbuf to NULL after kfree"

qctecmdr 3 lat temu
rodzic
commit
81152decfa
1 zmienionych plików z 3 dodań i 1 usunięć
  1. 3 1
      drivers/platform/msm/ipa/ipa_v3/ipa.c

+ 3 - 1
drivers/platform/msm/ipa/ipa_v3/ipa.c

@@ -9300,8 +9300,10 @@ fail_mem_ctrl:
 	kfree(ipa3_ctx->ipa_tz_unlock_reg);
 	ipa3_ctx->ipa_tz_unlock_reg = NULL;
 fail_tz_unlock_reg:
-	if (ipa3_ctx->logbuf)
+	if (ipa3_ctx->logbuf) {
 		ipc_log_context_destroy(ipa3_ctx->logbuf);
+		ipa3_ctx->logbuf = NULL;
+	}
 fail_uc_file_alloc:
 	kfree(ipa3_ctx->gsi_fw_file_name);
 	ipa3_ctx->gsi_fw_file_name = NULL;