mbox series

[v2,0/2] Avoid enabling LPI on non-ARM

Message ID 20220225190646.1045695-1-mario.limonciello@amd.com
Headers show
Series Avoid enabling LPI on non-ARM | expand

Message

Mario Limonciello Feb. 25, 2022, 7:06 p.m. UTC
On some AMD platforms the platform _OSC negotiation will lead to
`osc_pc_lpi_support_confirmed` being set and because the ACPI tables are
populated with `_LPI` entries the kernel will attempt to enable LPI.

On non-ARM kernels LPI is not supported and both
`acpi_processor_ffh_lpi_probe` and
`acpi_processor_ffh_lpi_enter` will return error codes.

When this happens there is no recourse though; the cpuidle code does
not switch to `_CST` mode, but rather it will continue to behave as though
LPI has been enabled and the CPU will remain in a high power state.

This patch series shifts the checks around while enabling LPI to detect
this situation and let the system continue to set up in _CST mode.

Link to v1: https://lore.kernel.org/linux-acpi/20220225031255.3647599-1-mario.limonciello@amd.com/T/#m90282a6e29c334d14b2854a27d7225fc57a22aa6

Mario Limonciello (2):
  PSCI: cpuidle: Move the `has_lpi` check to the beginning of the
    function
  ACPI: processor idle: Check for architectural support for LPI

 arch/arm64/kernel/cpuidle.c   |  6 +++---
 drivers/acpi/processor_idle.c | 15 ++++++++++-----
 2 files changed, 13 insertions(+), 8 deletions(-)