diff options
author | Sean Rhodes <sean@starlabs.systems> | 2024-02-19 21:02:30 +0000 |
---|---|---|
committer | Felix Held <felix-coreboot@felixheld.de> | 2024-06-07 18:31:50 +0000 |
commit | 2524c61df6f3c4a760f6a696ac152e71d3259c7b (patch) | |
tree | c3903cf9d3eb1262d7d3358bb1cb9f04a25b7ceb | |
parent | ee49088cc3b5396ba526e2980e2d73ea5f49a22e (diff) |
mb/starlabs/starbook/kbl: Use function for getting power profile
All other variants use a function and definitions to get the power
profile. Make this board to the same.
Change-Id: I07ce71e20bd71229bb0cd3438ab59140cd0d8b42
Signed-off-by: Sean Rhodes <sean@starlabs.systems>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/81412
Reviewed-by: Matt DeVillier <matt.devillier@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
-rw-r--r-- | src/mainboard/starlabs/starbook/variants/kbl/devtree.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/mainboard/starlabs/starbook/variants/kbl/devtree.c b/src/mainboard/starlabs/starbook/variants/kbl/devtree.c index 898519e876..64f638bf77 100644 --- a/src/mainboard/starlabs/starbook/variants/kbl/devtree.c +++ b/src/mainboard/starlabs/starbook/variants/kbl/devtree.c @@ -17,19 +17,19 @@ void devtree_update(void) struct device *nic_dev = pcidev_on_root(0x1c, 5); /* Update PL1 & PL2 based on CMOS settings */ - switch (get_uint_option("power_profile", 0)) { - case 1: - soc_conf->tdp_pl1_override = 17; - soc_conf->tdp_pl2_override = 20; + switch (get_power_profile(PP_POWER_SAVER)) { + case PP_POWER_SAVER: + disable_turbo(); + soc_conf->tdp_pl1_override = 15; + soc_conf->tdp_pl2_override = 15; break; - case 2: - soc_conf->tdp_pl1_override = 20; - soc_conf->tdp_pl2_override = 25; + case PP_BALANCED: + soc_conf->tdp_pl1_override = 17; + soc_conf->tdp_pl2_override = 20; break; - default: - disable_turbo(); - soc_conf->tdp_pl1_override = 15; - soc_conf->tdp_pl2_override = 15; + case PP_PERFORMANCE: + soc_conf->tdp_pl1_override = 20; + soc_conf->tdp_pl2_override = 25; break; } |