Skip to contentSkip to conversation

arm64: tegra: Add CPU and PSCI nodes for NVIDIA Tegra210 platforms

PATCH New Jon Hunter 5 participants 8 messages Mar 28, 2017 – Apr 9, 2017

Subsystems (2)
lore
Share & tools
lore

Jon Hunter

author maintainer
#0 lore raw

PATCH 1/1 arm64: tegra: Add CPU and PSCI nodes for NVIDIA Tegra210 platforms

Add the CPU and PSCI nodes for the NVIDIA Tegra210 platforms so that all CPUs can be enabled on boot. This assumes that the PSCI firmware has been loaded during the initial bootstrap on the device before the kernel starts (which is typically the case for these platforms). The PSCI firmware version is set to v0.2 which aligns with the current shipping version for Tegra.

---
 arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi | 23 +++++++++++++++++++++++
 arch/arm64/boot/dts/nvidia/tegra210-p2530.dtsi | 24 ++++++++++++++++++++++++
 2 files changed, 47 insertions(+)
arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi +23 -0
index 906fb836d241..de1696c28140 100644
@@ -296,6 +296,29 @@
 		};
 	};
 
+	cpus {
+		cpu at 0 {
+			enable-method = "psci";
+		};
+
+		cpu at 1 {
+			enable-method = "psci";
+		};
+
+		cpu at 2 {
+			enable-method = "psci";
+		};
+
+		cpu at 3 {
+			enable-method = "psci";
+		};
+	};
+
+	psci {
+		compatible = "arm,psci-0.2";
+		method = "smc";
+	};
+
 	regulators {
 		vdd_gpu: regulator at 100 {
 			compatible = "pwm-regulator";
arch/arm64/boot/dts/nvidia/tegra210-p2530.dtsi +24 -0
index 0ec92578cacb..67cb039965fd 100644
@@ -51,4 +51,28 @@
 			clock-frequency = <32768>;
 		};
 	};
+
+	cpus {
+		cpu at 0 {
+			enable-method = "psci";
+		};
+
+		cpu at 1 {
+			enable-method = "psci";
+		};
+
+		cpu at 2 {
+			enable-method = "psci";
+		};
+
+		cpu at 3 {
+			enable-method = "psci";
+		};
+	};
+
+	psci {
+		compatible = "arm,psci-0.2";
+		method = "smc";
+	};
+
 };
Signature · 1 line
2.7.4
#1 lore raw

PATCH 1/1 arm64: tegra: Add CPU and PSCI nodes for NVIDIA Tegra210 platforms

Quoted 19 lines · Jon Hunter

Add the CPU and PSCI nodes for the NVIDIA Tegra210 platforms so that all CPUs can be enabled on boot. This assumes that the PSCI firmware has been loaded during the initial bootstrap on the device before the kernel starts (which is typically the case for these platforms). The PSCI firmware version is set to v0.2 which aligns with the current shipping version for Tegra.

---
 arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi | 23 +++++++++++++++++++++++
 arch/arm64/boot/dts/nvidia/tegra210-p2530.dtsi | 24 ++++++++++++++++++++++++
 2 files changed, 47 insertions(+)
arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi +0 -0
index 906fb836d241..de1696c28140 100644

arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi line 301

Quoted 6 lines
arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi +3 -0
@@ -296,6 +296,29 @@
 		};
 	};
 
+	cpus {
+		cpu at 0 {
+			enable-method = "psci";

Is some firmware expected to populate other required properties ?

If yes, why not populate everything in the firmware ?

If no, how does it even boot secondaries without the "reg" property that usually contains MPIDR.

Signature · 2 lines
Regards,
Sudeep
author maintainer
#2 lore raw

PATCH 1/1 arm64: tegra: Add CPU and PSCI nodes for NVIDIA Tegra210 platforms

Quoted 29 lines · Sudeep Holla
Quoted 19 lines · Jon Hunter

Add the CPU and PSCI nodes for the NVIDIA Tegra210 platforms so that all CPUs can be enabled on boot. This assumes that the PSCI firmware has been loaded during the initial bootstrap on the device before the kernel starts (which is typically the case for these platforms). The PSCI firmware version is set to v0.2 which aligns with the current shipping version for Tegra.

---
 arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi | 23 +++++++++++++++++++++++
 arch/arm64/boot/dts/nvidia/tegra210-p2530.dtsi | 24 ++++++++++++++++++++++++
 2 files changed, 47 insertions(+)
arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi +0 -0
index 906fb836d241..de1696c28140 100644

arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi line 301

Quoted 6 lines
arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi +3 -0
@@ -296,6 +296,29 @@
 		};
 	};
 
+	cpus {
+		cpu at 0 {
+			enable-method = "psci";

Is some firmware expected to populate other required properties ?

Quoted 4 lines

If yes, why not populate everything in the firmware ?

If no, how does it even boot secondaries without the "reg" property that usually contains MPIDR.

Please see 'arch/arm64/boot/dts/nvidia/tegra210.dtsi' which has these fields. So far we have been populating the psci information at the board level and so I have kept with that here and so the above is just the delta. Maybe the $subject could be a little clearer!

Jon

Signature · 1 line
nvpublic
#3 lore raw

PATCH 1/1 arm64: tegra: Add CPU and PSCI nodes for NVIDIA Tegra210 platforms

Quoted 33 lines · Jon Hunter
Quoted 31 lines · Sudeep Holla
Quoted 19 lines · Jon Hunter

Add the CPU and PSCI nodes for the NVIDIA Tegra210 platforms so that all CPUs can be enabled on boot. This assumes that the PSCI firmware has been loaded during the initial bootstrap on the device before the kernel starts (which is typically the case for these platforms). The PSCI firmware version is set to v0.2 which aligns with the current shipping version for Tegra.

---
 arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi | 23 +++++++++++++++++++++++
 arch/arm64/boot/dts/nvidia/tegra210-p2530.dtsi | 24 ++++++++++++++++++++++++
 2 files changed, 47 insertions(+)
arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi +0 -0
index 906fb836d241..de1696c28140 100644

arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi line 301

Quoted 6 lines
arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi +3 -0
@@ -296,6 +296,29 @@
 		};
 	};
 
+	cpus {
+		cpu at 0 {
+			enable-method = "psci";

Is some firmware expected to populate other required properties ?

If yes, why not populate everything in the firmware ?

Quoted 7 lines
Quoted 2 lines

If no, how does it even boot secondaries without the "reg" property that usually contains MPIDR.

Please see 'arch/arm64/boot/dts/nvidia/tegra210.dtsi' which has these fields. So far we have been populating the psci information at the board level and so I have kept with that here and so the above is just the delta. Maybe the $subject could be a little clearer!

Sorry for the noise, I traversed files/headers upwards and missed the innermost tegra210.dtsi :(

Signature · 2 lines
Regards,
Sudeep
#4 lore raw

PATCH 1/1 arm64: tegra: Add CPU and PSCI nodes for NVIDIA Tegra210 platforms

In reply to Jon Hunter
Quoted 6 lines · Jon Hunter

Add the CPU and PSCI nodes for the NVIDIA Tegra210 platforms so that all CPUs can be enabled on boot. This assumes that the PSCI firmware has been loaded during the initial bootstrap on the device before the kernel starts (which is typically the case for these platforms). The PSCI firmware version is set to v0.2 which aligns with the current shipping version for Tegra.

This seems fine, although I'd expect PSCI to be used everywhere on Tegra, so putting this in tegra210.dtsi would make more sense.

author maintainer
#5 lore raw

PATCH 1/1 arm64: tegra: Add CPU and PSCI nodes for NVIDIA Tegra210 platforms

Quoted 10 lines · Stephen Warren
Quoted 6 lines · Jon Hunter

Add the CPU and PSCI nodes for the NVIDIA Tegra210 platforms so that all CPUs can be enabled on boot. This assumes that the PSCI firmware has been loaded during the initial bootstrap on the device before the kernel starts (which is typically the case for these platforms). The PSCI firmware version is set to v0.2 which aligns with the current shipping version for Tegra.

This seems fine, although I'd expect PSCI to be used everywhere on Tegra, so putting this in tegra210.dtsi would make more sense.

It's fine with me. Although technically, tegra210-smaug ships with psci-v1.0 and tegra210-jetson-tx1 currently have psci-v0.2. However, I did test both with the psci version set to v1.0 and the jetson-tx1, did detect the version automatically and reverted to v0.2 (which is a feature of psci >= v0.2). For Tegra186 we also have the psci node in the tegra186-p3310.dtsi.

Jon

Signature · 1 line
nvpublic
#6 lore raw

PATCH 1/1 arm64: tegra: Add CPU and PSCI nodes for NVIDIA Tegra210 platforms

Quoted 10 lines · Jon Hunter
Quoted 8 lines · Stephen Warren
Quoted 6 lines · Jon Hunter

Add the CPU and PSCI nodes for the NVIDIA Tegra210 platforms so that all CPUs can be enabled on boot. This assumes that the PSCI firmware has been loaded during the initial bootstrap on the device before the kernel starts (which is typically the case for these platforms). The PSCI firmware version is set to v0.2 which aligns with the current shipping version for Tegra.

Quoted 8 lines
Quoted 2 lines

This seems fine, although I'd expect PSCI to be used everywhere on Tegra, so putting this in tegra210.dtsi would make more sense.

It's fine with me. Although technically, tegra210-smaug ships with psci-v1.0 and tegra210-jetson-tx1 currently have psci-v0.2. However, I did test both with the psci version set to v1.0 and the jetson-tx1, did detect the version automatically and reverted to v0.2 (which is a feature of psci >= v0.2).

Please don't rely upon that.

If the DT lists 0.2 and the FW reports 1.0 we deliberately upgrade and treat it as 1.0, but the other way around was not a deliberate decision.

If the FW is not necessarily 1.0, please do not list 1.0 in the DT.

Thanks,
Mark.

#7 lore raw

PATCH 1/1 arm64: tegra: Add CPU and PSCI nodes for NVIDIA Tegra210 platforms

In reply to Jon Hunter
Quoted 9 lines · Jon Hunter

Add the CPU and PSCI nodes for the NVIDIA Tegra210 platforms so that all CPUs can be enabled on boot. This assumes that the PSCI firmware has been loaded during the initial bootstrap on the device before the kernel starts (which is typically the case for these platforms). The PSCI firmware version is set to v0.2 which aligns with the current shipping version for Tegra.

Tested on a jetson-tx1; all CPUs were recognized.

Quoted 74 lines
---
 arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi | 23 +++++++++++++++++++++++
 arch/arm64/boot/dts/nvidia/tegra210-p2530.dtsi | 24 ++++++++++++++++++++++++
 2 files changed, 47 insertions(+)
arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi +23 -0
index 906fb836d241..de1696c28140 100644
@@ -296,6 +296,29 @@
 		};
 	};
 
+	cpus {
+		cpu at 0 {
+			enable-method = "psci";
+		};
+
+		cpu at 1 {
+			enable-method = "psci";
+		};
+
+		cpu at 2 {
+			enable-method = "psci";
+		};
+
+		cpu at 3 {
+			enable-method = "psci";
+		};
+	};
+
+	psci {
+		compatible = "arm,psci-0.2";
+		method = "smc";
+	};
+
 	regulators {
 		vdd_gpu: regulator at 100 {
 			compatible = "pwm-regulator";
arch/arm64/boot/dts/nvidia/tegra210-p2530.dtsi +24 -0
index 0ec92578cacb..67cb039965fd 100644
@@ -51,4 +51,28 @@
 			clock-frequency = <32768>;
 		};
 	};
+
+	cpus {
+		cpu at 0 {
+			enable-method = "psci";
+		};
+
+		cpu at 1 {
+			enable-method = "psci";
+		};
+
+		cpu at 2 {
+			enable-method = "psci";
+		};
+
+		cpu at 3 {
+			enable-method = "psci";
+		};
+	};
+
+	psci {
+		compatible = "arm,psci-0.2";
+		method = "smc";
+	};
+
 };
Signature · 1 line
2.7.4

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 832 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20170408/ff6044d6/attachment.sig>