From: Ashish Mhetre <amhetre@nvidia.com>
To: Jon Hunter <jonathanh@nvidia.com>,
will@kernel.org, robin.murphy@arm.com, joro@8bytes.org,
robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org,
nicolinc@nvidia.com
Cc: thierry.reding@gmail.com, vdumpa@nvidia.com, jgg@ziepe.ca,
linux-arm-kernel@lists.infradead.org, iommu@lists.linux.dev,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-tegra@vger.kernel.org
Subject: Re: [PATCH V7 3/4] dt-bindings: iommu: Add NVIDIA Tegra CMDQV support
Date: Thu, 18 Dec 2025 12:33:52 +0530 [thread overview]
Message-ID: <38364cfe-8fc9-4ed7-9034-4e67584ee965@nvidia.com> (raw)
In-Reply-To: <fbde672b-611a-4d81-ac05-44e434bf70ae@nvidia.com>
On 12/18/2025 2:01 AM, Jon Hunter wrote:
>
>
> On 15/12/2025 06:48, Ashish Mhetre wrote:
>> The Command Queue Virtualization (CMDQV) hardware is part of the
>> SMMUv3 implementation on NVIDIA Tegra SoCs. It assists in
>> virtualizing the command queue for the SMMU.
>>
>> Add a new device tree binding document for nvidia,tegra264-cmdqv.
>>
>> Also update the arm,smmu-v3 binding to include an optional nvidia,cmdqv
>> property. This property is a phandle to the CMDQV device node, allowing
>> the SMMU driver to associate with its corresponding CMDQV instance.
>> Restrict this property usage to Nvidia Tegra264 only.
>>
>> Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
>> Signed-off-by: Ashish Mhetre <amhetre@nvidia.com>
>> ---
>> .../bindings/iommu/arm,smmu-v3.yaml | 30 ++++++++++++-
>> .../bindings/iommu/nvidia,tegra264-cmdqv.yaml | 42 +++++++++++++++++++
>> 2 files changed, 70 insertions(+), 2 deletions(-)
>> create mode 100644
>> Documentation/devicetree/bindings/iommu/nvidia,tegra264-cmdqv.yaml
>>
>> diff --git a/Documentation/devicetree/bindings/iommu/arm,smmu-v3.yaml
>> b/Documentation/devicetree/bindings/iommu/arm,smmu-v3.yaml
>> index 75fcf4cb52d9..1c03482e4c61 100644
>> --- a/Documentation/devicetree/bindings/iommu/arm,smmu-v3.yaml
>> +++ b/Documentation/devicetree/bindings/iommu/arm,smmu-v3.yaml
>> @@ -20,7 +20,12 @@ properties:
>> $nodename:
>> pattern: "^iommu@[0-9a-f]*"
>> compatible:
>> - const: arm,smmu-v3
>> + oneOf:
>> + - const: arm,smmu-v3
>> + - items:
>> + - enum:
>> + - nvidia,tegra264-smmu
>> + - const: arm,smmu-v3
>> reg:
>> maxItems: 1
>> @@ -58,6 +63,15 @@ properties:
>> msi-parent: true
>> + nvidia,cmdqv:
>> + description: |
>> + A phandle to its pairing CMDQV extension for an implementation
>> on NVIDIA
>> + Tegra SoC.
>> +
>> + If this property is absent, CMDQ-Virtualization won't be used
>> and SMMU
>> + will only use its own CMDQ.
>> + $ref: /schemas/types.yaml#/definitions/phandle
>> +
>> hisilicon,broken-prefetch-cmd:
>> type: boolean
>> description: Avoid sending CMD_PREFETCH_* commands to the SMMU.
>> @@ -69,6 +83,17 @@ properties:
>> register access with page 0 offsets. Set for Cavium ThunderX2
>> silicon that
>> doesn't support SMMU page1 register space.
>> +allOf:
>> + - if:
>> + not:
>> + properties:
>> + compatible:
>> + contains:
>> + const: nvidia,tegra264-smmu
>> + then:
>> + properties:
>> + nvidia,cmdqv: false
>> +
>> required:
>> - compatible
>> - reg
>> @@ -82,7 +107,7 @@ examples:
>> #include <dt-bindings/interrupt-controller/irq.h>
>> iommu@2b400000 {
>> - compatible = "arm,smmu-v3";
>> + compatible = "nvidia,tegra264-smmu", "arm,smmu-v3";
>> reg = <0x2b400000 0x20000>;
>> interrupts = <GIC_SPI 74 IRQ_TYPE_EDGE_RISING>,
>> <GIC_SPI 75 IRQ_TYPE_EDGE_RISING>,
>> @@ -92,4 +117,5 @@ examples:
>> dma-coherent;
>> #iommu-cells = <1>;
>> msi-parent = <&its 0xff0000>;
>> + nvidia,cmdqv = <&cmdqv>;
>
> So I believe that this is a generic example for arm,smmu-v3, and so I
> am not sure we want to be adding all these NVIDIA specific bits here.
> What would be more appropriate is to add another example under the
> existing example specifically for Tegra264.
>
> Jon
>
Yeah, makes sense. However, I checked arm-smmu.yaml (v2) binding docs
and we had separate Nvidia specific compatible and property
(nvidia,memory-controller) there as well. But we didn't have a separate
example for showing this compatible and property. So, I wonder if we
even need to update the generic smmuv3 example for cmdqv property or
add a new example?
Can you all please share your inputs on this?
If required, I'll update the patch will the change below:
diff --git a/Documentation/devicetree/bindings/iommu/arm,smmu-v3.yaml
b/Documentation/devicetree/bindings/iommu/arm,smmu-v3.yaml
index 1c03482e4c61..6b07ca9928a7 100644
--- a/Documentation/devicetree/bindings/iommu/arm,smmu-v3.yaml
+++ b/Documentation/devicetree/bindings/iommu/arm,smmu-v3.yaml
@@ -107,7 +107,7 @@ examples:
#include <dt-bindings/interrupt-controller/irq.h>
iommu@2b400000 {
- compatible = "nvidia,tegra264-smmu", "arm,smmu-v3";
+ compatible = "arm,smmu-v3";
reg = <0x2b400000 0x20000>;
interrupts = <GIC_SPI 74 IRQ_TYPE_EDGE_RISING>,
<GIC_SPI 75 IRQ_TYPE_EDGE_RISING>,
@@ -117,5 +117,26 @@ examples:
dma-coherent;
#iommu-cells = <1>;
msi-parent = <&its 0xff0000>;
+ };
+
+ - |+
+ /* Example for NVIDIA Tegra264 with CMDQV extension */
+ #include <dt-bindings/interrupt-controller/arm-gic.h>
+ #include <dt-bindings/interrupt-controller/irq.h>
+
+ iommu@5000000 {
+ compatible = "nvidia,tegra264-smmu", "arm,smmu-v3";
+ reg = <0x5000000 0x200000>;
+ interrupts = <GIC_SPI 12 IRQ_TYPE_EDGE_RISING>,
+ <GIC_SPI 13 IRQ_TYPE_EDGE_RISING>;
+ interrupt-names = "eventq", "gerror";
+ dma-coherent;
+ #iommu-cells = <1>;
nvidia,cmdqv = <&cmdqv>;
};
+
+ cmdqv: cmdqv@5200000 {
+ compatible = "nvidia,tegra264-cmdqv";
+ reg = <0x5200000 0x830000>;
+ interrupts = <GIC_SPI 19 IRQ_TYPE_LEVEL_HIGH>;
+ };
Thanks,
Ashish Mhetre
next prev parent reply other threads:[~2025-12-18 7:37 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-15 6:48 [PATCH V7 0/4] Add device tree support for NVIDIA Tegra CMDQV Ashish Mhetre
2025-12-15 6:48 ` [PATCH V7 1/4] iommu/tegra241-cmdqv: Decouple driver from ACPI Ashish Mhetre
2025-12-15 6:48 ` [PATCH V7 2/4] iommu/arm-smmu-v3: Add device-tree support for CMDQV driver Ashish Mhetre
2025-12-17 20:43 ` Jon Hunter
2025-12-18 6:32 ` Ashish Mhetre
2025-12-18 8:48 ` Jon Hunter
2025-12-18 18:57 ` Nicolin Chen
2025-12-19 10:48 ` Jon Hunter
2025-12-19 18:49 ` Nicolin Chen
2026-01-07 6:44 ` Ashish Mhetre
2026-01-09 9:45 ` Jon Hunter
2026-01-13 5:12 ` Ashish Mhetre
2025-12-15 6:48 ` [PATCH V7 3/4] dt-bindings: iommu: Add NVIDIA Tegra CMDQV support Ashish Mhetre
2025-12-15 21:19 ` Nicolin Chen
2025-12-17 20:31 ` Jon Hunter
2025-12-18 7:03 ` Ashish Mhetre [this message]
2026-01-07 6:49 ` Ashish Mhetre
2026-01-09 9:47 ` Jon Hunter
2026-01-13 5:09 ` Ashish Mhetre
2025-12-15 6:48 ` [PATCH V7 4/4] arm64: dts: nvidia: Add nodes for CMDQV Ashish Mhetre
2025-12-15 21:21 ` Nicolin Chen
2025-12-17 20:42 ` Jon Hunter
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=38364cfe-8fc9-4ed7-9034-4e67584ee965@nvidia.com \
--to=amhetre@nvidia.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=iommu@lists.linux.dev \
--cc=jgg@ziepe.ca \
--cc=jonathanh@nvidia.com \
--cc=joro@8bytes.org \
--cc=krzk+dt@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tegra@vger.kernel.org \
--cc=nicolinc@nvidia.com \
--cc=robh@kernel.org \
--cc=robin.murphy@arm.com \
--cc=thierry.reding@gmail.com \
--cc=vdumpa@nvidia.com \
--cc=will@kernel.org \
/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