Skip to content
Commit 5836ebeb authored by Sudeep Holla's avatar Sudeep Holla Committed by Rafael J. Wysocki
Browse files

cpuidle: psci: Avoid initializing faux device if no DT idle states are present



Commit af5376a7 ("cpuidle: psci: Transition to the faux device interface")
transitioned the PSCI cpuidle driver from using a platform device to the
faux device framework. However, unlike platform devices, the faux device
infrastructure logs an error when the probe function fails, even if the
failure is intentional or expected.

To prevent unnecessary error logs, we can skip creating the faux device
entirely if there are no PSCI idle states defined in the device tree.
Introduce a check for DT idle states during initialization and avoid
setting up the device if none are found.

This ensures cleaner logs and avoids misleading probe failure messages
when PSCI idle support is intentionally not described in DT.

Fixes: af5376a7 ("cpuidle: psci: Transition to the faux device interface")
Reported-by: default avatarJon Hunter <jonathanh@nvidia.com>
Closes: https://lore.kernel.org/r/cf4e70e4-9fe5-4697-8744-8c12c41b5ff9@nvidia.com


Signed-off-by: Sudeep Holla's avatarSudeep Holla <sudeep.holla@arm.com>
Reviewed-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
Link: https://patch.msgid.link/20250502140119.2578909-1-sudeep.holla@arm.com


Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent e80e1342
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment