From: Sumit Garg <sumit.garg@kernel.org>
To: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org,
andersson@kernel.org, konradybcio@kernel.org, robh@kernel.org,
krzk+dt@kernel.org, conor+dt@kernel.org,
akhilpo@oss.qualcomm.com, vikash.garodia@oss.qualcomm.com,
dikshita.agarwal@oss.qualcomm.com, robin.clark@oss.qualcomm.com,
lumag@kernel.org, linux-kernel@vger.kernel.org,
Sumit Garg <sumit.garg@oss.qualcomm.com>,
Prakash Gupta <guptap@qti.qualcomm.com>
Subject: Re: [PATCH 1/2] arm64: dts: qcom: agatti: Fix IOMMU DT properties
Date: Tue, 30 Dec 2025 13:24:23 +0530 [thread overview]
Message-ID: <aVOFL3jmNrFNiYV0@sumit-xelite> (raw)
In-Reply-To: <yudvagpfw3tfemvf3wcr62jrlvxfo5yobgsrzj4nechtqdxeu6@i2pfy4ys6qlj>
On Tue, Dec 30, 2025 at 09:05:28AM +0200, Dmitry Baryshkov wrote:
> On Tue, Dec 30, 2025 at 10:45:38AM +0530, Sumit Garg wrote:
> > On Mon, Dec 29, 2025 at 10:00:02PM +0200, Dmitry Baryshkov wrote:
> > > On Mon, Dec 29, 2025 at 12:42:57PM +0530, Sumit Garg wrote:
> > > > From: Sumit Garg <sumit.garg@oss.qualcomm.com>
> > > >
> > > > Fix IOMMU DT propeties for GPU, display and video peripherals via
> > > > dropping SMMU stream IDs which relates to secure context bank.
> > > >
> > > > This problem only surfaced when the Gunyah based firmware stack is
> > > > ported on Agatti replacing the legacy QHEE based firmware stack. Assigning
> > > > Linux kernel (HLOS) VMID to secure context bank stream IDs is treated
> > > > as a fault by Gunyah hypervisor which were previously ignored by QHEE
> > > > hypervisor.
> > >
> > > We are porting the underlaying layer. Can we make it to behave in a way
> > > similar to the _existing_ software? If DT was a part of the firmware, it
> > > would have been fine to perform such updates. But as it is not, we
> > > really should try not to break the interface boundary between firmware
> > > and the kernel.
> >
> > I support your viewpoint. But in this current case Linux kernel VMID mapping
> > for secure context bank stream IDs is incorrect. As Konrad mentioned in the
> > other thread that for secure media streaming use-cases, it rather requires
> > proper representation via iommu-map such that appropriate VMID can be mapped.
>
> Yes, I understand this part. I'm basically suggesting that Gunyah should
> ignore this SID when programming the actual SMMU (probably like QHEE
> did).
TBH, I generally dislike as to why the firmware based hypervisor
behaviour should be encoded in the DT. One can always argue that Gunyah
is doing the right thing given the purpose of SMMU stream IDs. And if
Gunyah has to change that behaviour since Agatti DT was based on QHEE
behaviour then the same behaviour will get replicated on all other Qcom
SoCs.
So, I would suggest that kernel should follow the expected behaviour
which is to not program HLOS VMID for stream IDs dedicated for secure
context bank.
>
> >
> > >
> > > I'm fine with the change, but I think we should make sure that Gunyah
> > > doesn't break existing device trees.
> >
> > Sure, this change isn't breaking any DT ABI but brings compliance to
> > usage of stream IDs.
>
> Actually, it does, as you can see from Rob's email. You didn't perform
> make dtbs_check while submitting this patch.
Okay, I missed that. Looks like the GPU DT node already defined minItems
for the iommus property but the others didn't. I will add following
change in the next version to fix the warnings.
Irrespective on that, the DT forwards and backwards ABI compatibility is
being maintained with the changes being proposed in this patch-set.
diff --git a/Documentation/devicetree/bindings/display/msm/qcom,qcm2290-mdss.yaml b/Documentation/devicetree/bindings/display/msm/qcom,qcm2290-mdss.yaml
index f0cdb5422688..e5e62c5bab42 100644
--- a/Documentation/devicetree/bindings/display/msm/qcom,qcm2290-mdss.yaml
+++ b/Documentation/devicetree/bindings/display/msm/qcom,qcm2290-mdss.yaml
@@ -33,6 +33,7 @@ properties:
- const: core
iommus:
+ minItems: 1
maxItems: 2
interconnects:
diff --git a/Documentation/devicetree/bindings/media/qcom,qcm2290-venus.yaml b/Documentation/devicetree/bindings/media/qcom,qcm2290-venus.yaml
index 3f3ee82fc878..8d4371697867 100644
--- a/Documentation/devicetree/bindings/media/qcom,qcm2290-venus.yaml
+++ b/Documentation/devicetree/bindings/media/qcom,qcm2290-venus.yaml
@@ -42,6 +42,7 @@ properties:
- const: vcodec0_bus
iommus:
+ minItems: 2
maxItems: 5
interconnects:
-Sumit
next prev parent reply other threads:[~2025-12-30 7:54 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-29 7:12 [PATCH 1/2] arm64: dts: qcom: agatti: Fix IOMMU DT properties Sumit Garg
2025-12-29 7:12 ` [PATCH 2/2] arm64: dts: qcom: agatti: Address Gunyah memory alignment needs Sumit Garg
2025-12-29 12:42 ` Konrad Dybcio
2025-12-29 12:43 ` Konrad Dybcio
2025-12-30 4:46 ` Sumit Garg
2025-12-30 13:07 ` Konrad Dybcio
2026-01-03 15:49 ` Bjorn Andersson
2026-01-05 5:46 ` Sumit Garg
2026-01-07 11:29 ` Konrad Dybcio
2026-01-08 10:50 ` Sumit Garg
2026-01-08 12:43 ` Konrad Dybcio
2026-01-09 10:07 ` Sumit Garg
2025-12-29 12:41 ` [PATCH 1/2] arm64: dts: qcom: agatti: Fix IOMMU DT properties Konrad Dybcio
2025-12-29 20:00 ` Dmitry Baryshkov
2025-12-30 5:15 ` Sumit Garg
2025-12-30 7:05 ` Dmitry Baryshkov
2025-12-30 7:54 ` Sumit Garg [this message]
2026-01-03 15:43 ` Bjorn Andersson
2026-01-05 6:27 ` Sumit Garg
2025-12-30 12:46 ` Akhil P Oommen
2025-12-30 14:40 ` Dmitry Baryshkov
2025-12-29 20:39 ` Rob Herring
2025-12-29 21:27 ` Akhil P Oommen
-- strict thread matches above, loose matches on Subject: below --
2025-12-29 7:07 Sumit Garg
2025-12-29 7:20 ` Sumit Garg
2026-01-02 10:02 ` Vikash Garodia
2026-01-02 11:52 ` Sumit Garg
2026-01-05 7:21 ` Vikash Garodia
2026-01-06 2:38 ` Dmitry Baryshkov
2026-01-06 5:42 ` Sumit Garg
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=aVOFL3jmNrFNiYV0@sumit-xelite \
--to=sumit.garg@kernel.org \
--cc=akhilpo@oss.qualcomm.com \
--cc=andersson@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dikshita.agarwal@oss.qualcomm.com \
--cc=dmitry.baryshkov@oss.qualcomm.com \
--cc=guptap@qti.qualcomm.com \
--cc=konradybcio@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lumag@kernel.org \
--cc=robh@kernel.org \
--cc=robin.clark@oss.qualcomm.com \
--cc=sumit.garg@oss.qualcomm.com \
--cc=vikash.garodia@oss.qualcomm.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