Hello Duan huayang,
I'd like you to do a code review. Please visit
https://review.coreboot.org/c/coreboot/+/39097
to review the following change.
Change subject: soc/mediatek/mt8183: Add get dram type API at ATF ......................................................................
soc/mediatek/mt8183: Add get dram type API at ATF
DVFS module need know the dram type at ATF for loading the correct spm binary.
BRANCH=kukui BUG=none TEST=bootup pass
Change-Id: I20afc00c4c671abcbb6f36eb8e3e364529e9389c Signed-off-by: Huayang Duan huayang.duan@mediatek.com --- M src/mainboard/google/kukui/mainboard.c 1 file changed, 11 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/97/39097/1
diff --git a/src/mainboard/google/kukui/mainboard.c b/src/mainboard/google/kukui/mainboard.c index 844496d..da39c1c 100644 --- a/src/mainboard/google/kukui/mainboard.c +++ b/src/mainboard/google/kukui/mainboard.c @@ -184,8 +184,19 @@ .gpio = { .polarity = ARM_TF_GPIO_LEVEL_HIGH }, };
+ /* use .polarity to save dram type value */ + static struct bl_aux_param_gpio param_dram_type = { + .h = { .type = BL_AUX_PARAM_MTK_DRAM_TYPE }, +#if CONFIG(MT8183_DRAM_EMCP) + .gpio = { .polarity = DRAMC_CONFIG_EMCP }, +#else + .gpio = { .polarity = 0 }, +#endif + }; + param_reset.gpio.index = GPIO_RESET.id; register_bl31_aux_param(¶m_reset.h); + register_bl31_aux_param(¶m_dram_type.h); }
static void mainboard_init(struct device *dev)