OSDN Git Service

firmware: psci: Export functions to manage the OSI mode
authorUlf Hansson <ulf.hansson@linaro.org>
Thu, 10 Oct 2019 10:01:48 +0000 (12:01 +0200)
committerUlf Hansson <ulf.hansson@linaro.org>
Thu, 2 Jan 2020 15:49:59 +0000 (16:49 +0100)
commit49fdcd7577efe9efe863cdbb154f32a96970c1bc
tree326ecc6f8d698f2e1006777b0def4f41377f4cc1
parenta3f048b5424e68f0f7218c51e84d7b84ab0143cb
firmware: psci: Export functions to manage the OSI mode

To allow subsequent changes to implement support for OSI mode through the
cpuidle-psci driver, export the existing psci_has_osi_support(). Export
also a new function, psci_set_osi_mode(), that allows its caller to enable
the OS-initiated CPU-suspend mode in the PSCI FW.

To deal with backwards compatibility for a kernel started through a kexec
call, default to set the CPU-suspend mode to the Platform Coordinated mode
during boot.

Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Reviewed-by: Sudeep Holla <sudeep.holla@arm.com>
drivers/firmware/psci/psci.c
include/linux/psci.h