diff mbox series

[2/2] ARM: tegra: Enable PSCI support for Tegra210 and Tegra186

Message ID 20200618115439.25100-2-jonathanh@nvidia.com
State Accepted
Commit 1ec74533840650b914ccdf9f62a298ecb29994ab
Headers show
Series [1/2] firmware: PSCI: Fix PSCI support for OF live trees | expand

Commit Message

Jon Hunter June 18, 2020, 11:54 a.m. UTC
The PSCI nodes are currently not populated for the Tegra210 and Tegra186
devices. This prevents the PSCI driver from being able to identify the
PSCI method used by these devices and causes the probe of the PSCI
driver to fail.

Since commit 81ea00838c68 ("efi_loader: PSCI reset and shutdown") was
added, which moves the PSCI EFI system reset handler into the PSCI
driver, this has prevented the EFI system reset from working for
Tegra210 and Tegra186. Therefore, populating these nodes is necessary
to fix the EFI system reset for Tegra210 and Tegra186.

Signed-off-by: Jon Hunter <jonathanh at nvidia.com>
---
 arch/arm/dts/tegra186.dtsi | 5 +++++
 arch/arm/dts/tegra210.dtsi | 5 +++++
 2 files changed, 10 insertions(+)

Comments

Peter Robinson June 18, 2020, 3:44 p.m. UTC | #1
On Thu, Jun 18, 2020 at 12:56 PM Jon Hunter <jonathanh at nvidia.com> wrote:
>
> The PSCI nodes are currently not populated for the Tegra210 and Tegra186
> devices. This prevents the PSCI driver from being able to identify the
> PSCI method used by these devices and causes the probe of the PSCI
> driver to fail.
>
> Since commit 81ea00838c68 ("efi_loader: PSCI reset and shutdown") was
> added, which moves the PSCI EFI system reset handler into the PSCI
> driver, this has prevented the EFI system reset from working for
> Tegra210 and Tegra186. Therefore, populating these nodes is necessary
> to fix the EFI system reset for Tegra210 and Tegra186.
>
> Signed-off-by: Jon Hunter <jonathanh at nvidia.com>
Tested-by: Peter Robinson <pbrobinson at gmail.com>

Tested on the Jetson Nano and it now reboots as expected.
> ---
>  arch/arm/dts/tegra186.dtsi | 5 +++++
>  arch/arm/dts/tegra210.dtsi | 5 +++++
>  2 files changed, 10 insertions(+)
>
> diff --git a/arch/arm/dts/tegra186.dtsi b/arch/arm/dts/tegra186.dtsi
> index 0a9db9825b85..edcb7aacb8ee 100644
> --- a/arch/arm/dts/tegra186.dtsi
> +++ b/arch/arm/dts/tegra186.dtsi
> @@ -335,4 +335,9 @@
>                         status = "disabled";
>                 };
>         };
> +
> +       psci {
> +               compatible = "arm,psci-1.0";
> +               method = "smc";
> +       };
>  };
> diff --git a/arch/arm/dts/tegra210.dtsi b/arch/arm/dts/tegra210.dtsi
> index 3ec54b11c43f..a521a43d6cfd 100644
> --- a/arch/arm/dts/tegra210.dtsi
> +++ b/arch/arm/dts/tegra210.dtsi
> @@ -867,6 +867,11 @@
>                 };
>         };
>
> +       psci {
> +               compatible = "arm,psci-1.0";
> +               method = "smc";
> +       };
> +
>         timer {
>                 compatible = "arm,armv8-timer";
>                 interrupts = <GIC_PPI 13
> --
> 2.17.1
>
Stephen Warren June 22, 2020, 7:04 p.m. UTC | #2
On 6/18/20 5:54 AM, Jon Hunter wrote:
> The PSCI nodes are currently not populated for the Tegra210 and Tegra186
> devices. This prevents the PSCI driver from being able to identify the
> PSCI method used by these devices and causes the probe of the PSCI
> driver to fail.
> 
> Since commit 81ea00838c68 ("efi_loader: PSCI reset and shutdown") was
> added, which moves the PSCI EFI system reset handler into the PSCI
> driver, this has prevented the EFI system reset from working for
> Tegra210 and Tegra186. Therefore, populating these nodes is necessary
> to fix the EFI system reset for Tegra210 and Tegra186.

I'm not sure that these platforms have *always* had a PSCI
implementation, so this is a slight assumption. Ideally, the FW should
add this to the DT and pass it to U-Boot... However, since all recentish
FW builds do implement PSCI, and the DT is hard-coded into U-Boot rather
than provided by the earlier FW, this change is probably just fine.
diff mbox series

Patch

diff --git a/arch/arm/dts/tegra186.dtsi b/arch/arm/dts/tegra186.dtsi
index 0a9db9825b85..edcb7aacb8ee 100644
--- a/arch/arm/dts/tegra186.dtsi
+++ b/arch/arm/dts/tegra186.dtsi
@@ -335,4 +335,9 @@ 
 			status = "disabled";
 		};
 	};
+
+	psci {
+		compatible = "arm,psci-1.0";
+		method = "smc";
+	};
 };
diff --git a/arch/arm/dts/tegra210.dtsi b/arch/arm/dts/tegra210.dtsi
index 3ec54b11c43f..a521a43d6cfd 100644
--- a/arch/arm/dts/tegra210.dtsi
+++ b/arch/arm/dts/tegra210.dtsi
@@ -867,6 +867,11 @@ 
 		};
 	};
 
+	psci {
+		compatible = "arm,psci-1.0";
+		method = "smc";
+	};
+
 	timer {
 		compatible = "arm,armv8-timer";
 		interrupts = <GIC_PPI 13