From: Albert Esteve <aesteve@redhat.com>
To: Bjorn Andersson <andersson@kernel.org>,
Konrad Dybcio <konradybcio@kernel.org>
Cc: linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org,
Albert Esteve <aesteve@redhat.com>,
Tony Truong <quic_truong@quicinc.com>
Subject: [PATCH 2/2] soc: qcom: smem: ignore multi remote host partitions
Date: Thu, 20 Aug 2026 13:34:19 +0200 [thread overview]
Message-ID: <20260820-port-smem-v1-2-d19a45f583bf@redhat.com> (raw)
In-Reply-To: <20260820-port-smem-v1-0-d19a45f583bf@redhat.com>
From: Tony Truong <quic_truong@quicinc.com>
SMEM now supports more than just 1-to-1 partitions. It is possible for
a partition to have multiple remote host and the logic to handle that
does not exist. For now, skip all partitions which has multiple remote
hosts.
Signed-off-by: Tony Truong <quic_truong@quicinc.com>
Signed-off-by: Albert Esteve <aesteve@redhat.com>
---
drivers/soc/qcom/smem.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/drivers/soc/qcom/smem.c b/drivers/soc/qcom/smem.c
index 194ffb2ac010f..8e079d2381535 100644
--- a/drivers/soc/qcom/smem.c
+++ b/drivers/soc/qcom/smem.c
@@ -86,6 +86,9 @@
/* Processor/host identifier for the global partition */
#define SMEM_GLOBAL_HOST 0xfffe
+/* Processor/host identifier for multi host partition */
+#define SMEM_MULTI_HOST 0xfffc
+
/* Entry range check
* ptr >= start : Checks if ptr is greater than the start of access region
* ptr + size >= ptr: Check for integer overflow (On 32bit system where ptr
@@ -1081,6 +1084,9 @@ qcom_smem_enumerate_partitions(struct qcom_smem *smem, u16 local_host)
else
continue;
+ if (remote_host == SMEM_MULTI_HOST)
+ continue;
+
if (xa_load(&smem->partitions, remote_host)) {
dev_err(smem->dev, "duplicate host %u\n", remote_host);
return -EINVAL;
--
2.55.0
prev parent reply other threads:[~2026-08-20 11:34 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-20 11:34 [PATCH 0/2] Add automotive SMEM hardening for Qualcomm platforms Albert Esteve
2026-08-20 11:34 ` [PATCH 1/2] soc: qcom: smem: add boundary checks for partitions Albert Esteve
2026-08-31 22:54 ` Bjorn Andersson
2026-09-01 7:04 ` Albert Esteve
2026-09-30 17:10 ` Deepak Kumar Singh
2026-10-01 8:38 ` Albert Esteve
2026-08-20 11:34 ` Albert Esteve [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260820-port-smem-v1-2-d19a45f583bf@redhat.com \
--to=aesteve@redhat.com \
--cc=andersson@kernel.org \
--cc=konradybcio@kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=quic_truong@quicinc.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®