Skip to contentSkip to conversation

arm64: tegra: A few device-tree fixes

PATCH Applied Jon Hunter 2 participants 7 messages Jun 20, 2019

Subsystems (3)
lore
Share & tools
lore

Jon Hunter

author maintainer
#0 lore raw

cover arm64: tegra: A few device-tree fixes

Here are a few device-tree fixes for Tegra210 GPU regulator and AGIC.

Jon Hunter (3):
arm64: tegra: Fix AGIC register range
arm64: tegra: Update Jetson TX1 GPU regulator timings
arm64: tegra: Fix Jetson Nano GPU regulator

 .../arm64/boot/dts/nvidia/tegra210-p2180.dtsi |  3 ++-
 .../boot/dts/nvidia/tegra210-p3450-0000.dts   | 21 +++++++++++--------
 arch/arm64/boot/dts/nvidia/tegra210.dtsi      |  2 +-
 3 files changed, 15 insertions(+), 11 deletions(-)
Signature · 1 line
2.17.1
author maintainer
#1 lore raw

PATCH 1/3 arm64: tegra: Fix AGIC register range

The Tegra AGIC interrupt controller is an ARM GIC400 interrupt controller. Per the ARM GIC device-tree binding, the first address region is for the GIC distributor registers and the second address region is for the GIC CPU interface registers. The address space for the distributor registers is 4kB, but currently this is incorrectly defined as 8kB for the Tegra AGIC and overlaps with the CPU interface registers. Correct the address space for the distributor to be 4kB.

---
 arch/arm64/boot/dts/nvidia/tegra210.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/nvidia/tegra210.dtsi +1 -1
index edf27fe2f10e..ec762b3455b4 100644
@@ -1258,7 +1258,7 @@
 			compatible = "nvidia,tegra210-agic";
 			#interrupt-cells = <3>;
 			interrupt-controller;
-			reg = <0x702f9000 0x2000>,
+			reg = <0x702f9000 0x1000>,
 			      <0x702fa000 0x2000>;
 			interrupts = <GIC_SPI 102 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>;
 			clocks = <&tegra_car TEGRA210_CLK_APE>;
Signature · 1 line
2.17.1
#2 lore raw

Re: [PATCH 1/3] arm64: tegra: Fix AGIC register range

Quoted 8 lines · Jon Hunter

The Tegra AGIC interrupt controller is an ARM GIC400 interrupt controller. Per the ARM GIC device-tree binding, the first address region is for the GIC distributor registers and the second address region is for the GIC CPU interface registers. The address space for the distributor registers is 4kB, but currently this is incorrectly defined as 8kB for the Tegra AGIC and overlaps with the CPU interface registers. Correct the address space for the distributor to be 4kB.

Quoted 5 lines
---
 arch/arm64/boot/dts/nvidia/tegra210.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Applied to for-5.3/arm64/dt, though I also added the following Fixes:
line:

Fixes bcdbde433542 ("arm64: tegra: Add AGIC node for Tegra210")

Thanks,
Thierry

author maintainer
#3 lore raw

PATCH 2/3 arm64: tegra: Update Jetson TX1 GPU regulator timings

In reply to Jon Hunter

The GPU regulator enable ramp delay for Jetson TX1 is set to 1ms which not sufficient because the enable ramp delay has been measured to be greater than 1ms. Furthermore, the downstream kernels released by NVIDIA for Jetson TX1 are using a enable ramp delay 2ms and a settling delay of 160us. Update the GPU regulator enable ramp delay for Jetson TX1 to be 2ms and add a settling delay of 160us.

---
 arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi +2 -1
index e8654061ce03..27723829d033 100644
@@ -341,7 +341,8 @@
 			regulator-max-microvolt = <1320000>;
 			enable-gpios = <&pmic 6 GPIO_ACTIVE_HIGH>;
 			regulator-ramp-delay = <80>;
-			regulator-enable-ramp-delay = <1000>;
+			regulator-enable-ramp-delay = <2000>;
+			regulator-settling-time-us = <160>;
 		};
 	};
 };
Signature · 1 line
2.17.1
#4 lore raw

Re: [PATCH 2/3] arm64: tegra: Update Jetson TX1 GPU regulator timings

Quoted 7 lines · Jon Hunter

The GPU regulator enable ramp delay for Jetson TX1 is set to 1ms which not sufficient because the enable ramp delay has been measured to be greater than 1ms. Furthermore, the downstream kernels released by NVIDIA for Jetson TX1 are using a enable ramp delay 2ms and a settling delay of 160us. Update the GPU regulator enable ramp delay for Jetson TX1 to be 2ms and add a settling delay of 160us.

Quoted 5 lines
---
 arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Applied to for-5.3/arm64/dt, and I added this Fixes: line:

Fixes 5e6b9a89afce ("arm64: tegra: Add VDD_GPU regulator to Jetson TX1")

Thanks,
Thierry

author maintainer
#5 lore raw

PATCH 3/3 arm64: tegra: Fix Jetson Nano GPU regulator

In reply to Jon Hunter

There are a few issues with the GPU regulator defined for Jetson Nano which are:

1. The GPU regulator is a PWM based regulator and not a fixed voltage regulator.
2. The output voltages for the GPU regulator are not correct.
3. The regulator enable ramp delay is too short for the regulator and needs to be increased. 2ms should be sufficient.
4. This is the same regulator used on Jetson TX1 and so make the ramp delay and settling time the same as Jetson TX1.

---
 .../boot/dts/nvidia/tegra210-p3450-0000.dts   | 21 +++++++++++--------
 1 file changed, 12 insertions(+), 9 deletions(-)
arch/arm64/boot/dts/nvidia/tegra210-p3450-0000.dts +12 -9
index 63df72eecf21..9d17ec707bce 100644
@@ -88,6 +88,10 @@
 		status = "okay";
 	};
 
+	pwm@7000a000 {
+		status = "okay";
+	};
+
 	i2c@7000c500 {
 		status = "okay";
 		clock-frequency = <100000>;
@@ -664,17 +668,16 @@
 		};
 
 		vdd_gpu: regulator@6 {
-			compatible = "regulator-fixed";
+			compatible = "pwm-regulator";
 			reg = <6>;
-
+			pwms = <&pwm 1 4880>;
 			regulator-name = "VDD_GPU";
-			regulator-min-microvolt = <5000000>;
-			regulator-max-microvolt = <5000000>;
-			regulator-enable-ramp-delay = <250>;
-
-			gpio = <&pmic 6 GPIO_ACTIVE_HIGH>;
-			enable-active-high;
-
+			regulator-min-microvolt = <710000>;
+			regulator-max-microvolt = <1320000>;
+			regulator-ramp-delay = <80>;
+			regulator-enable-ramp-delay = <2000>;
+			regulator-settling-time-us = <160>;
+			enable-gpios = <&pmic 6 GPIO_ACTIVE_HIGH>;
 			vin-supply = <&vdd_5v0_sys>;
 		};
 	};
Signature · 1 line
2.17.1
#6 lore raw

Re: [PATCH 3/3] arm64: tegra: Fix Jetson Nano GPU regulator

Quoted 11 lines · Jon Hunter

There are a few issues with the GPU regulator defined for Jetson Nano which are:

1. The GPU regulator is a PWM based regulator and not a fixed voltage regulator.
2. The output voltages for the GPU regulator are not correct.
3. The regulator enable ramp delay is too short for the regulator and needs to be increased. 2ms should be sufficient.
4. This is the same regulator used on Jetson TX1 and so make the ramp delay and settling time the same as Jetson TX1.

Quoted 5 lines
---
 .../boot/dts/nvidia/tegra210-p3450-0000.dts   | 21 +++++++++++--------
 1 file changed, 12 insertions(+), 9 deletions(-)

Applied to for-5.3/arm64/dt and added the following Fixes: line:

Fixes 6772cd0eacc8 ("arm64: tegra: Add NVIDIA Jetson Nano Developer Kit support")

Thanks,
Thierry