From: Pankaj Patil <pankaj.patil@oss.qualcomm.com>
To: Shivendra Pratap <shivendra.pratap@oss.qualcomm.com>,
Lorenzo Pieralisi <lpieralisi@kernel.org>,
Arnd Bergmann <arnd@arndb.de>,
Bjorn Andersson <andersson@kernel.org>,
Sebastian Reichel <sre@kernel.org>, Rob Herring <robh@kernel.org>,
Souvik Chakravarty <Souvik.Chakravarty@arm.com>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Andy Yan <andy.yan@rock-chips.com>,
Matthias Brugger <matthias.bgg@gmail.com>,
Mark Rutland <mark.rutland@arm.com>,
Conor Dooley <conor+dt@kernel.org>,
Konrad Dybcio <konradybcio@kernel.org>,
John Stultz <john.stultz@linaro.org>,
Moritz Fischer <moritz.fischer@ettus.com>,
Bartosz Golaszewski <brgl@kernel.org>,
Sudeep Holla <sudeep.holla@kernel.org>
Cc: Florian Fainelli <florian.fainelli@broadcom.com>,
Krzysztof Kozlowski <krzk@kernel.org>,
Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>,
Mukesh Ojha <mukesh.ojha@oss.qualcomm.com>,
Andre Draszik <andre.draszik@linaro.org>,
Kathiravan Thirumoorthy
<kathiravan.thirumoorthy@oss.qualcomm.com>,
linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org,
Srinivas Kandagatla <srini@kernel.org>,
Song Xue <quic_songxue@quicinc.com>
Subject: Re: [PATCH v20 00/10] Implement PSCI reboot mode driver for PSCI resets
Date: Mon, 6 Apr 2026 13:06:34 +0530 [thread overview]
Message-ID: <c8fbb242-c1df-4db5-8fda-705e9df4a894@oss.qualcomm.com> (raw)
In-Reply-To: <20260304-arm-psci-system_reset2-vendor-reboots-v20-0-cf7d346b8372@oss.qualcomm.com>
On 3/4/2026 11:33 PM, Shivendra Pratap wrote:
> Userspace should be able to initiate device reboots using the various
> PSCI SYSTEM_RESET and SYSTEM_RESET2 types defined by PSCI spec. This
> patch series introduces psci-reboot-mode driver that registers with
> reboot-mode framework to provide this functionality.
>
> The PSCI system reset calls takes two arguments: reset_type and cookie.
> It defines predefined reset types, such as warm and cold reset, and
> vendor-specific reset types which are SoC vendor specific. To support
> these requirements, the reboot-mode framework is enhanced in two key
> ways:
> 1. 64-bit magic support: Extend reboot-mode to handle two 32-bit
> arguments (reset_type and cookie) by encoding them into a single 64-bit
> magic value.
> 2. Predefined modes: Add support for predefined reboot modes in the
> framework.
>
> With these enhancements, the patch series enables:
> - Warm reset and cold reset as predefined reboot modes.
> - Vendor-specific resets exposed as tunables, configurable via the
> SoC-specific device tree.
>
> Together, these changes allow userspace to trigger all above PSCI resets
> from userspace.
>
> Currently three drivers register with reboot-mode framework -
> syscon-reboot-mode, nvmem-reboot-mode and qcom-pon. Consolidated
> list of commands currently added across various vendor DTs:
> mode-loader
> mode-normal
> mode-bootloader
> mode-charge
> mode-fastboot
> mode-reboot-ab-update
> mode-recovery
> mode-rescue
> mode-shutdown-thermal
> mode-shutdown-thermal-battery
>
> On gs101 we also pass kernel-generated modes from kernel_restart()
> or panic(), specifically DM verity's 'dm-verity device corrupted':
> mode-dm-verity-device-corrupted = <0x50>;
>
> - thanks Andre' for providing this.
>
> Detailed list of commands being used by syscon-reboot-mode:
> arm64/boot/dts/exynos/exynosautov9.dtsi:
> mode-bootloader = <EXYNOSAUTOV9_BOOT_BOOTLOADER>;
> mode-fastboot = <EXYNOSAUTOV9_BOOT_FASTBOOT>;
> mode-recovery = <EXYNOSAUTOV9_BOOT_RECOVERY>;
>
> arm64/boot/dts/exynos/google/gs101.dtsi:
> mode-bootloader = <0xfc>;
> mode-charge = <0x0a>;
> mode-fastboot = <0xfa>;
> mode-reboot-ab-update = <0x52>;
> mode-recovery = <0xff>;
> mode-rescue = <0xf9>;
> mode-shutdown-thermal = <0x51>;
> mode-shutdown-thermal-battery = <0x51>;
>
> arm64/boot/dts/hisilicon/hi3660-hikey960.dts:
> mode-normal = <0x77665501>;
> mode-bootloader = <0x77665500>;
> mode-recovery = <0x77665502>;
>
> arm64/boot/dts/hisilicon/hi6220-hikey.dts:
> mode-normal = <0x77665501>;
> mode-bootloader = <0x77665500>;
> mode-recovery = <0x77665502>;
>
> arm64/boot/dts/rockchip/px30.dtsi:
> mode-bootloader = <BOOT_BL_DOWNLOAD>;
> mode-fastboot = <BOOT_FASTBOOT>;
> mode-loader = <BOOT_BL_DOWNLOAD>;
> mode-normal = <BOOT_NORMAL>;
> mode-recovery = <BOOT_RECOVERY>;
>
> arm64/boot/dts/rockchip/rk3308.dtsi:
> mode-bootloader = <BOOT_BL_DOWNLOAD>;
> mode-loader = <BOOT_BL_DOWNLOAD>;
> mode-normal = <BOOT_NORMAL>;
> mode-recovery = <BOOT_RECOVERY>;
> mode-fastboot = <BOOT_FASTBOOT>;
>
> arm64/boot/dts/rockchip/rk3566-lckfb-tspi.dts:
> mode-normal = <BOOT_NORMAL>;
> mode-loader = <BOOT_BL_DOWNLOAD>;
> mode-recovery = <BOOT_RECOVERY>;
> mode-bootloader = <BOOT_FASTBOOT>;
>
> Detailed list of commands being used by nvmem-reboot-mode:
> arm64/boot/dts/qcom/pmXXXX.dtsi:(multiple qcom DTs)
> mode-recovery = <0x01>;
> mode-bootloader = <0x02>;
>
> The patch is tested on rb3Gen2, lemans-ride, lemans-evk, monaco-ride,
> qcs615-ride.
>
> @Florian/@Kathiravan, Please note that reset_type in DT needs to be
> full in itself with 31st bit set. (eg: 0x80000000).
>
> PS: As advised from Lorenzo, "PSCI maintainers should be added as
> maintainers for psci-reboot-mode".
>
> Previous discussions around SYSTEM_RESET2:
> - https://lore.kernel.org/lkml/20230724223057.1208122-2-quic_eberman@quicinc.com/T/
> - https://lore.kernel.org/all/4a679542-b48d-7e11-f33a-63535a5c68cb@quicinc.com/
>
> Signed-off-by: Shivendra Pratap <shivendra.pratap@oss.qualcomm.com>
>
Tested-by: Pankaj Patil <pankaj.patil@oss.qualcomm.com>
prev parent reply other threads:[~2026-04-06 7:36 UTC|newest]
Thread overview: 40+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-04 18:03 [PATCH v20 00/10] Implement PSCI reboot mode driver for PSCI resets Shivendra Pratap
2026-03-04 18:03 ` [PATCH v20 01/10] power: reset: reboot-mode: Remove devres based allocations Shivendra Pratap
2026-03-05 10:05 ` Bartosz Golaszewski
2026-03-11 9:21 ` Sebastian Reichel
2026-03-12 8:54 ` Shivendra Pratap
2026-04-01 15:19 ` Krzysztof Kozlowski
2026-04-02 6:15 ` Shivendra Pratap
2026-03-04 18:03 ` [PATCH v20 02/10] power: reset: reboot-mode: Add support for 64 bit magic Shivendra Pratap
2026-03-11 9:22 ` Sebastian Reichel
2026-03-04 18:03 ` [PATCH v20 03/10] power: reset: reboot-mode: Add support for predefined reboot modes Shivendra Pratap
2026-03-11 9:22 ` Sebastian Reichel
2026-03-04 18:03 ` [PATCH v20 04/10] firmware: psci: Introduce command-based reset in psci_sys_reset Shivendra Pratap
2026-03-27 14:07 ` Lorenzo Pieralisi
2026-03-31 17:38 ` Shivendra Pratap
2026-03-04 18:03 ` [PATCH v20 05/10] dt-bindings: arm: Document reboot mode magic Shivendra Pratap
2026-03-04 18:03 ` [PATCH v20 06/10] power: reset: Add psci-reboot-mode driver Shivendra Pratap
2026-03-05 10:02 ` Bartosz Golaszewski
2026-03-05 17:06 ` Shivendra Pratap
2026-03-06 13:32 ` Bartosz Golaszewski
2026-03-27 14:08 ` Lorenzo Pieralisi
2026-03-27 14:09 ` Bartosz Golaszewski
2026-03-27 13:55 ` Lorenzo Pieralisi
2026-03-27 13:59 ` Bartosz Golaszewski
2026-03-31 18:00 ` Shivendra Pratap
2026-04-01 14:37 ` Lorenzo Pieralisi
2026-04-01 14:56 ` Arnd Bergmann
2026-04-02 18:38 ` Shivendra Pratap
2026-04-02 18:35 ` Shivendra Pratap
2026-04-03 15:50 ` Lorenzo Pieralisi
2026-04-03 17:45 ` Shivendra Pratap
2026-03-27 14:14 ` Lorenzo Pieralisi
2026-03-31 17:40 ` Shivendra Pratap
2026-03-04 18:03 ` [PATCH v20 07/10] arm64: dts: qcom: qcm6490: Add psci reboot-modes Shivendra Pratap
2026-03-05 10:57 ` Konrad Dybcio
2026-03-04 18:03 ` [PATCH v20 08/10] arm64: dts: qcom: lemans: " Shivendra Pratap
2026-03-05 11:33 ` Konrad Dybcio
2026-03-05 17:52 ` Shivendra Pratap
2026-03-04 18:03 ` [PATCH v20 09/10] arm64: dts: qcom: monaco: " Shivendra Pratap
2026-03-04 18:03 ` [PATCH v20 10/10] arm64: dts: qcom: talos: " Shivendra Pratap
2026-04-06 7:36 ` Pankaj Patil [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=c8fbb242-c1df-4db5-8fda-705e9df4a894@oss.qualcomm.com \
--to=pankaj.patil@oss.qualcomm.com \
--cc=Souvik.Chakravarty@arm.com \
--cc=andersson@kernel.org \
--cc=andre.draszik@linaro.org \
--cc=andy.yan@rock-chips.com \
--cc=arnd@arndb.de \
--cc=brgl@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dmitry.baryshkov@oss.qualcomm.com \
--cc=florian.fainelli@broadcom.com \
--cc=john.stultz@linaro.org \
--cc=kathiravan.thirumoorthy@oss.qualcomm.com \
--cc=konradybcio@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=krzk@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=lpieralisi@kernel.org \
--cc=mark.rutland@arm.com \
--cc=matthias.bgg@gmail.com \
--cc=moritz.fischer@ettus.com \
--cc=mukesh.ojha@oss.qualcomm.com \
--cc=quic_songxue@quicinc.com \
--cc=robh@kernel.org \
--cc=shivendra.pratap@oss.qualcomm.com \
--cc=sre@kernel.org \
--cc=srini@kernel.org \
--cc=sudeep.holla@kernel.org \
/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