Changes in v3:
Rebased on top of https://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git/ next.
Resolved compile error seen with tegra194.dtsi changes after rebase.
v2 - https://lkml.org/lkml/2019/9/2/980
v1 - https://lkml.org/lkml/2019/8/29/1588
Krishna Reddy (7):
iommu/arm-smmu: prepare arm_smmu_flush_ops for override
iommu/arm-smmu: add NVIDIA implementation for dual ARM MMU-500 usage
dt-bindings: arm-smmu: Add binding for Tegra194 SMMU
iommu/arm-smmu: Add global/context fault implementation hooks
arm64: tegra: Add Memory controller DT node on T194
arm64: tegra: Add DT node for T194 SMMU
arm64: tegra: enable SMMU for SDHCI and EQOS on T194
.../devicetree/bindings/iommu/arm,smmu.txt | 4 +
MAINTAINERS | 2 +
arch/arm64/boot/dts/nvidia/tegra194-p2888.dtsi | 4 +
arch/arm64/boot/dts/nvidia/tegra194.dtsi | 88 +++++++
drivers/iommu/Makefile | 2 +-
drivers/iommu/arm-smmu-impl.c | 3 +
drivers/iommu/arm-smmu-nvidia.c | 287 +++++++++++++++++++++
drivers/iommu/arm-smmu.c | 27 +-
drivers/iommu/arm-smmu.h | 8 +-
9 files changed, 413 insertions(+), 12 deletions(-)
create mode 100644 drivers/iommu/arm-smmu-nvidia.c
--
2.7.4
Add Memory controller DT node on T194 and enable it.
This patch is a prerequisite for SMMU enable on T194.
Signed-off-by: Krishna Reddy <[email protected]>
---
arch/arm64/boot/dts/nvidia/tegra194-p2888.dtsi | 4 ++++
arch/arm64/boot/dts/nvidia/tegra194.dtsi | 6 ++++++
2 files changed, 10 insertions(+)
diff --git a/arch/arm64/boot/dts/nvidia/tegra194-p2888.dtsi b/arch/arm64/boot/dts/nvidia/tegra194-p2888.dtsi
index 4c38426..82a02490 100644
--- a/arch/arm64/boot/dts/nvidia/tegra194-p2888.dtsi
+++ b/arch/arm64/boot/dts/nvidia/tegra194-p2888.dtsi
@@ -47,6 +47,10 @@
};
};
+ memory-controller@2c00000 {
+ status = "okay";
+ };
+
serial@3110000 {
status = "okay";
};
diff --git a/arch/arm64/boot/dts/nvidia/tegra194.dtsi b/arch/arm64/boot/dts/nvidia/tegra194.dtsi
index 3c0cf54..1e0b54b 100644
--- a/arch/arm64/boot/dts/nvidia/tegra194.dtsi
+++ b/arch/arm64/boot/dts/nvidia/tegra194.dtsi
@@ -163,6 +163,12 @@
};
};
+ memory-controller@2c00000 {
+ compatible = "nvidia,tegra186-mc";
+ reg = <0x02c00000 0xb0000>;
+ status = "disabled";
+ };
+
uarta: serial@3100000 {
compatible = "nvidia,tegra194-uart", "nvidia,tegra20-uart";
reg = <0x03100000 0x40>;
--
2.7.4
Add binding for NVIDIA's Tegra194 Soc SMMU that is based
on ARM MMU-500.
Signed-off-by: Krishna Reddy <[email protected]>
---
Documentation/devicetree/bindings/iommu/arm,smmu.txt | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/Documentation/devicetree/bindings/iommu/arm,smmu.txt b/Documentation/devicetree/bindings/iommu/arm,smmu.txt
index 3133f3b..1d72fac 100644
--- a/Documentation/devicetree/bindings/iommu/arm,smmu.txt
+++ b/Documentation/devicetree/bindings/iommu/arm,smmu.txt
@@ -31,6 +31,10 @@ conditions.
as below, SoC-specific compatibles:
"qcom,sdm845-smmu-500", "arm,mmu-500"
+ NVIDIA SoCs that use more than one ARM MMU-500 together
+ needs following SoC-specific compatibles along with "arm,mmu-500":
+ "nvidia,tegra194-smmu"
+
- reg : Base address and size of the SMMU.
- #global-interrupts : The number of global interrupts exposed by the
--
2.7.4
Hi Krishna,
On 19/10/2019 00:31, Krishna Reddy wrote:
> Changes in v3:
> Rebased on top of https://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git/ next.
> Resolved compile error seen with tegra194.dtsi changes after rebase.
Apologies for crossed wires, but I had a series getting rid of
arm_smmu_flush_ops which was also meant to end up making things a bit
easier for you:
https://lore.kernel.org/linux-iommu/[email protected]/
Will, did you have any plans to push out an updates or iommu/devel
branch for Krishna to base on?
Robin.
>
> v2 - https://lkml.org/lkml/2019/9/2/980
> v1 - https://lkml.org/lkml/2019/8/29/1588
>
> Krishna Reddy (7):
> iommu/arm-smmu: prepare arm_smmu_flush_ops for override
> iommu/arm-smmu: add NVIDIA implementation for dual ARM MMU-500 usage
> dt-bindings: arm-smmu: Add binding for Tegra194 SMMU
> iommu/arm-smmu: Add global/context fault implementation hooks
> arm64: tegra: Add Memory controller DT node on T194
> arm64: tegra: Add DT node for T194 SMMU
> arm64: tegra: enable SMMU for SDHCI and EQOS on T194
>
> .../devicetree/bindings/iommu/arm,smmu.txt | 4 +
> MAINTAINERS | 2 +
> arch/arm64/boot/dts/nvidia/tegra194-p2888.dtsi | 4 +
> arch/arm64/boot/dts/nvidia/tegra194.dtsi | 88 +++++++
> drivers/iommu/Makefile | 2 +-
> drivers/iommu/arm-smmu-impl.c | 3 +
> drivers/iommu/arm-smmu-nvidia.c | 287 +++++++++++++++++++++
> drivers/iommu/arm-smmu.c | 27 +-
> drivers/iommu/arm-smmu.h | 8 +-
> 9 files changed, 413 insertions(+), 12 deletions(-)
> create mode 100644 drivers/iommu/arm-smmu-nvidia.c
>
On 19/10/2019 00:31, Krishna Reddy wrote:
> Add binding for NVIDIA's Tegra194 Soc SMMU that is based
> on ARM MMU-500.
>
> Signed-off-by: Krishna Reddy <[email protected]>
> ---
> Documentation/devicetree/bindings/iommu/arm,smmu.txt | 4 ++++
Rob (+cc) is in the process of converting the SMMU bindings to schema,
so we might need a bit of coordination here...
Robin.
> 1 file changed, 4 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/iommu/arm,smmu.txt b/Documentation/devicetree/bindings/iommu/arm,smmu.txt
> index 3133f3b..1d72fac 100644
> --- a/Documentation/devicetree/bindings/iommu/arm,smmu.txt
> +++ b/Documentation/devicetree/bindings/iommu/arm,smmu.txt
> @@ -31,6 +31,10 @@ conditions.
> as below, SoC-specific compatibles:
> "qcom,sdm845-smmu-500", "arm,mmu-500"
>
> + NVIDIA SoCs that use more than one ARM MMU-500 together
> + needs following SoC-specific compatibles along with "arm,mmu-500":
> + "nvidia,tegra194-smmu"
> +
> - reg : Base address and size of the SMMU.
>
> - #global-interrupts : The number of global interrupts exposed by the
>
Hi Robin,
>>Apologies for crossed wires, but I had a series getting rid of arm_smmu_flush_ops which was also meant to end up making things a bit easier for you:
I was looking to rebase on top of your changes first. Then I read Will's reply that said your work is queued for 5.5.
Let me know if these patches need to rebased on top of iommu/devel or a different branch. I can resend the patch set on top of necessary branch.
-KR
On Tue, Oct 22, 2019 at 11:48:55PM +0000, Krishna Reddy wrote:
> >>Apologies for crossed wires, but I had a series getting rid of
> >>arm_smmu_flush_ops which was also meant to end up making things a bit
> >>easier for you:
>
> I was looking to rebase on top of your changes first. Then I read Will's
> reply that said your work is queued for 5.5.
D'oh, sorry, I completely forgot to push that branch out. Now done:
https://git.kernel.org/pub/scm/linux/kernel/git/will/linux.git/log/?h=for-joerg/arm-smmu/updates
Will
>>https://git.kernel.org/pub/scm/linux/kernel/git/will/linux.git/log/?h=for-joerg/arm-smmu/updates
Thanks Will! Let me rebase my patches on top of this branch and send it out.
-KR