Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3c430049 authored by Kyle Yan's avatar Kyle Yan Committed by Gerrit - the friendly Code Review server
Browse files

Merge "soc: qcom: smem: Fix possible use of uninitialized variable" into msm-4.8

parents 1acad168 ea38a6e0
Loading
Loading
Loading
Loading
+12 −6
Original line number Diff line number Diff line
@@ -1222,12 +1222,18 @@ static void smem_init_security_partition(struct smem_toc_entry *entry,
		LOG_ERR("Smem partition %d cached heap exceeds size\n", num);
		BUG();
	}
	if (hdr->host0 == SMEM_COMM_HOST && hdr->host1 == SMEM_COMM_HOST) {
	if (is_comm_partition) {
		if (hdr->host0 == SMEM_COMM_HOST
			&& hdr->host1 == SMEM_COMM_HOST) {
			comm_partition.partition_num = num;
			comm_partition.offset = entry->offset;
			comm_partition.size_cacheline = entry->size_cacheline;
			SMEM_INFO("Common Partition %d offset:%x\n", num,
							entry->offset);
		} else {
			LOG_ERR("Smem Comm partition hosts don't match TOC\n");
			WARN_ON(1);
		}
		return;
	}
	if (hdr->host0 != SMEM_APPS && hdr->host1 != SMEM_APPS) {