mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Michael Olbrich <mol@pengutronix.de>,
	Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [PATCH 7/7] ARM: dts: stm32mp: report psci v0.2 at least
Date: Wed,  6 Nov 2019 08:10:34 +0100	[thread overview]
Message-ID: <20191106071034.24452-7-a.fatoum@pengutronix.de> (raw)
In-Reply-To: <20191106071034.24452-1-a.fatoum@pengutronix.de>

ARM TF-A reports compatibility with PSCI v1.1 since v1.5. Upstream
ARM TF-A support for STM32MP was introduced with v1.6.
It's thus safe to assume that the STM32MP barebox will never have to
interact with a secure monitor implementing PSCI v0.1.

Overwrite the psci device tree compatible to specify v0.2. This is the
first version that implements PSCI_VERSION, which allows the barebox
psci client driver selected in this commit to query the actual PSCI
version and fix it up into the device tree.

This fixes an issue where resetting via PSCI fails in Linux because the
upstream device tree compatible:

  reboot: Restarting system
  Reboot failed -- System halted

Reported-by: Michael Olbrich <mol@pengutronix.de>
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
 arch/arm/dts/stm32mp157c.dtsi | 4 ++++
 arch/arm/mach-stm32mp/Kconfig | 1 +
 2 files changed, 5 insertions(+)

diff --git a/arch/arm/dts/stm32mp157c.dtsi b/arch/arm/dts/stm32mp157c.dtsi
index 771139c28af0..97c075a020f8 100644
--- a/arch/arm/dts/stm32mp157c.dtsi
+++ b/arch/arm/dts/stm32mp157c.dtsi
@@ -19,6 +19,10 @@
 		gpio10 = &gpiok;
 		gpio25 = &gpioz;
 	};
+
+	psci {
+		compatible = "arm,psci-0.2";
+	};
 };
 
 &bsec {
diff --git a/arch/arm/mach-stm32mp/Kconfig b/arch/arm/mach-stm32mp/Kconfig
index b30439735e17..e74029158223 100644
--- a/arch/arm/mach-stm32mp/Kconfig
+++ b/arch/arm/mach-stm32mp/Kconfig
@@ -5,6 +5,7 @@ config ARCH_NR_GPIO
 	default 416
 
 config ARCH_STM32MP157
+	select PSCI_CLIENT
 	bool
 
 config MACH_STM32MP157C_DK2
-- 
2.24.0.rc1


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

      parent reply	other threads:[~2019-11-06  7:10 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-06  7:10 [PATCH 1/7] misc: psci: translate PSCI error codes in smc command Ahmad Fatoum
2019-11-06  7:10 ` [PATCH 2/7] ARM: psci: use CONFIG_ARM_PSCI_DEBUG for " Ahmad Fatoum
2019-11-06  7:10 ` [PATCH 3/7] psci: wire in smc command help Ahmad Fatoum
2019-11-06  7:10 ` [PATCH 4/7] misc: implement PSCI client driver Ahmad Fatoum
2019-11-06  7:10 ` [PATCH 5/7] misc: implement PSCI system reset driver Ahmad Fatoum
2019-11-06  9:32   ` Sascha Hauer
2019-11-06  7:10 ` [PATCH 6/7] ARM: stm32mp: select ARM_USE_COMPRESSED_DTB for the whole arch Ahmad Fatoum
2019-11-06  7:10 ` Ahmad Fatoum [this message]

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=20191106071034.24452-7-a.fatoum@pengutronix.de \
    --to=a.fatoum@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=mol@pengutronix.de \
    /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