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

Commit 4b2fe7cd authored by Eric Holmberg's avatar Eric Holmberg Committed by Matt Wagantall
Browse files

soc: qcom: smem: add partition information



Upon initialization, SMEM scans the partition table to extract
information for any partitions that APSS is part of and the partition
information is stored for debug purposes.  If the APSS processor is not
part of the edge, then it is skipped and no information about the
partition is logged.

Log non-APSS partition information to assist in system triage.

Change-Id: I1609bb6c6f4f22637b7a709c4c09df783a45fa96
Signed-off-by: default avatarEric Holmberg <eholmber@codeaurora.org>
parent f5ca7bc6
Loading
Loading
Loading
Loading
+8 −4
Original line number Diff line number Diff line
@@ -1137,6 +1137,13 @@ static void smem_init_security_partition(struct smem_toc_entry *entry,

	hdr = smem_areas[0].virt_addr + entry->offset;

	if (entry->host0 != SMEM_APPS && entry->host1 != SMEM_APPS) {
		SMEM_INFO(
			"Non-APSS Partition %d offset:%x host0:%d host1:%d\n",
			num, entry->offset, entry->host0, entry->host1);
		return;
	}

	if (hdr->identifier != SMEM_PART_HDR_IDENTIFIER) {
		LOG_ERR("Smem partition %d hdr magic is bad\n", num);
		BUG();
@@ -1195,9 +1202,6 @@ static void smem_init_security(void)
		SMEM_DBG("Partition %d host0:%d host1:%d\n", i,
							toc->entry[i].host0,
							toc->entry[i].host1);

		if (toc->entry[i].host0 == SMEM_APPS ||
					toc->entry[i].host1 == SMEM_APPS)
		smem_init_security_partition(&toc->entry[i], i);
	}