From e822fb358764b78e7d7d02c024ae6a285632ddf9 Mon Sep 17 00:00:00 2001 From: Anil Kumar Date: Thu, 9 Feb 2023 16:55:57 -0800 Subject: soc/intel/alderlake: Disable package C-state demotion for Raptor Lake While executing S0ix tests on Raptor Lake boards, we observed CPU fails to enter suspend state, causing failure. As a workaround, disable package C-state demotion, till this issue is fixed in ucode. BUG=268296760 BRANCH=firmware-brya-14505.B TEST=Boot and verified that S0ix issue is resolved. Signed-off-by: Anil Kumar Change-Id: Ie50e1024f4118d82d2ad762b54fa722c43990d12 Reviewed-on: https://review.coreboot.org/c/coreboot/+/72942 Reviewed-by: Eric Lai Tested-by: build bot (Jenkins) Reviewed-by: Subrata Banik Reviewed-by: Nick Vaccaro --- src/soc/intel/alderlake/fsp_params.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/soc') diff --git a/src/soc/intel/alderlake/fsp_params.c b/src/soc/intel/alderlake/fsp_params.c index 4117c2215a..42475c4561 100644 --- a/src/soc/intel/alderlake/fsp_params.c +++ b/src/soc/intel/alderlake/fsp_params.c @@ -937,6 +937,7 @@ static void fill_fsps_cpu_pcie_params(FSP_S_CONFIG *s_cfg, static void fill_fsps_misc_power_params(FSP_S_CONFIG *s_cfg, const struct soc_intel_alderlake_config *config) { + u32 cpu_id = cpu_get_cpuid(); /* Skip setting D0I3 bit for all HECI devices */ s_cfg->DisableD0I3SettingForHeci = 1; /* @@ -1005,7 +1006,11 @@ static void fill_fsps_misc_power_params(FSP_S_CONFIG *s_cfg, s_cfg->VrPowerDeliveryDesign = config->vr_power_delivery_design; - s_cfg->PkgCStateDemotion = !config->disable_package_c_state_demotion; + /* FIXME: Disable package C state demotion on Raptorlake as a W/A for S0ix issues */ + if ((cpu_id == CPUID_RAPTORLAKE_P_J0) || (cpu_id == CPUID_RAPTORLAKE_P_Q0)) + s_cfg->PkgCStateDemotion = 0; + else + s_cfg->PkgCStateDemotion = !config->disable_package_c_state_demotion; } static void fill_fsps_irq_params(FSP_S_CONFIG *s_cfg, -- cgit v1.2.3