Tristan Hsieh has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/32466 )
Change subject: google/kukui: Raising the CPU frequency ......................................................................
Patch Set 2:
According to pmic spec (MT6358_PMIC_Data_Sheet_V1.3.pdf), the voltage will be stable in 200us. It takes about 700us from increasing voltage to end of mt6358_init(). So, it's safe to raising CPU frequency after mt6538_init()
Here is my test patch: diff --git a/src/soc/mediatek/mt8183/mt6358.c b/src/soc/mediatek/mt8183/mt6358.c index 8162e3a..81e7fde 100644 --- a/src/soc/mediatek/mt8183/mt6358.c +++ b/src/soc/mediatek/mt8183/mt6358.c @@ -772,7 +772,7 @@ static void mt6358_lp_setting(void) lp_setting[i].addr, lp_setting[i].val, lp_setting[i].mask, lp_setting[i].shift); } - +#include <timestamp.h> void mt6358_init(void) { if (pwrap_init()) @@ -781,7 +781,9 @@ void mt6358_init(void) pmic_set_power_hold(true); pmic_wdt_set(); mt6358_init_setting(); +timestamp_add_now(TS_START_KERNEL); wk_sleep_voltage_by_ddr(); wk_power_down_seq(); mt6358_lp_setting(); +timestamp_add_now(TS_START_KERNEL); }
Log...
1:start of romstage 334,046 (1) 1101:jumping to kernel 336,516 (2,470) 1101:jumping to kernel 337,273 (757)