soc/intel/alderlake: Move C State Demotion to mainboard config

Rather than disabling C State demotions for every single Raptor
Lake board due to an issue with S0ix, regardless of if they even
use S0ix, configure it in the mainboard.

Signed-off-by: Sean Rhodes <sean@starlabs.systems>
Change-Id: I4f941a549bc717ae2f8ec961ead7ac7668347c99
Reviewed-on: https://review.coreboot.org/c/coreboot/+/77087
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Martin L Roth <gaumless@gmail.com>
This commit is contained in:
Sean Rhodes 2023-08-08 13:46:53 +01:00 committed by Martin L Roth
parent fa25954066
commit 42f8b59c11
5 changed files with 20 additions and 5 deletions

View File

@ -14,6 +14,10 @@ chip soc/intel/alderlake
# S0ix enable
register "s0ix_enable" = "1"
# Disable package C state demotion on Raptorlake as a W/A for S0ix issues
# seen on J0 and Q0 SKUs
register "disable_package_c_state_demotion" = "1"
# DPTF enable
register "dptf_enable" = "1"

View File

@ -1,4 +1,7 @@
chip soc/intel/alderlake
# Disable package C state demotion on Raptorlake as a W/A for S0ix issues
# seen on J0 and Q0 SKUs
register "disable_package_c_state_demotion" = "1"
device domain 0 on end
end

View File

@ -1,4 +1,7 @@
chip soc/intel/alderlake
# Disable package C state demotion on Raptorlake as a W/A for S0ix issues
# seen on J0 and Q0 SKUs
register "disable_package_c_state_demotion" = "1"
device domain 0 on
device ref pch_espi on

View File

@ -17,6 +17,10 @@ chip soc/intel/alderlake
# Thermal
register "tcc_offset" = "8"
# Disable package C state demotion on Raptorlake as a W/A for S0ix issues
# seen on J0 and Q0 SKUs
register "disable_package_c_state_demotion" = "1"
device cpu_cluster 0 on end
device domain 0 on

View File

@ -1061,11 +1061,12 @@ static void fill_fsps_misc_power_params(FSP_S_CONFIG *s_cfg,
s_cfg->VrPowerDeliveryDesign = config->vr_power_delivery_design;
/* FIXME: Disable package C state demotion on Raptorlake as a W/A for S0ix issues */
if ((cpu_id == CPUID_RAPTORLAKE_J0) || (cpu_id == CPUID_RAPTORLAKE_Q0))
s_cfg->PkgCStateDemotion = 0;
else
s_cfg->PkgCStateDemotion = !config->disable_package_c_state_demotion;
/* C state demotion must be disabled for Raptorlake J0 and Q0 SKUs */
assert(!(config->s0ix_enable && ((cpu_id == CPUID_RAPTORLAKE_J0) ||
(cpu_id == CPUID_RAPTORLAKE_Q0)) &&
!config->disable_package_c_state_demotion));
s_cfg->PkgCStateDemotion = !config->disable_package_c_state_demotion;
if (cpu_id == CPUID_RAPTORLAKE_J0 || cpu_id == CPUID_RAPTORLAKE_Q0)
s_cfg->C1e = 0;