acpi: Configure slp-s0 residency counter frequency in LPIT table
Intel platforms use Low Power Idle Table (LPIT) to enumerate platform Low Power Idle states. There are two types of low power residencies a) CPU PKG C10 - read via MSR (Function fixed hardware interface) b) Platform Controller Hub (PCH) SLP_S0 - read via memory mapped Ref. https://www.uefi.org/sites/default/files/resources/Intel_ACPI_Low_Power_S0_Idle.pdf System sleep time (SLP_S0 signal asserted) is measured in ticks, varies in every platform and based on PMC clock. BUG=b:300440936 TEST=check kernel cpuidle sysfs for non-zero residency after s0ix cycle and both must match cat /sys/devices/system/cpu/cpuidle/low_power_idle_system_residency_us cat /sys/kernel/debug/pmc_core/slp_s0_residency_usec Change-Id: I401dd4a09a67d81a9ea3a56cd22f1a681e2a9349 Signed-off-by: Sukumar Ghorai <sukumar.ghorai@intel.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/78164 Reviewed-by: Subrata Banik <subratabanik@google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
parent
93ca15cc83
commit
bd9c562a9e
|
@ -454,7 +454,12 @@ typedef struct acpi_lpi_desc_hdr {
|
||||||
} __packed acpi_lpi_desc_hdr_t;
|
} __packed acpi_lpi_desc_hdr_t;
|
||||||
|
|
||||||
#define ACPI_LPIT_CTR_FREQ_TSC 0
|
#define ACPI_LPIT_CTR_FREQ_TSC 0
|
||||||
#define ACPI_LPIT_SLP_S0_FREQ 0
|
#if defined CONFIG_ACPI_SOC_INTEL_SLP_S0_FREQ_HZ && CONFIG_ACPI_SOC_INTEL_SLP_S0_FREQ_HZ != 0
|
||||||
|
#define ACPI_LPIT_SLP_S0_FREQ CONFIG_ACPI_SOC_INTEL_SLP_S0_FREQ_HZ
|
||||||
|
#else
|
||||||
|
#define ACPI_LPIT_SLP_S0_FREQ 0
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/* LPIT: Native C-state instruction based LPI structure */
|
/* LPIT: Native C-state instruction based LPI structure */
|
||||||
typedef struct acpi_lpi_desc_ncst {
|
typedef struct acpi_lpi_desc_ncst {
|
||||||
|
|
Loading…
Reference in New Issue