diff options
author | Elyes HAOUAS <ehaouas@noos.fr> | 2019-12-08 14:05:32 +0100 |
---|---|---|
committer | Patrick Georgi <pgeorgi@google.com> | 2019-12-10 11:20:59 +0000 |
commit | 12520134f17b55ac7f695d1d9384e33a99b18def (patch) | |
tree | 7de07e22e2f101badd6f0d6028c0fa20e7f222de /src | |
parent | 9e052c2b6c4a30771ff282286bec5d78d4422c72 (diff) | |
download | coreboot-12520134f17b55ac7f695d1d9384e33a99b18def.tar.xz |
mb/google/daisy: Move 'PMIC_BUS' to Kconfig
Change-Id: If40fa38e5b249452a6dacf4a4045b6bd00c27cfa
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/37580
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
Diffstat (limited to 'src')
-rw-r--r-- | src/mainboard/google/daisy/Kconfig | 4 | ||||
-rw-r--r-- | src/mainboard/google/daisy/romstage.c | 22 |
2 files changed, 14 insertions, 12 deletions
diff --git a/src/mainboard/google/daisy/Kconfig b/src/mainboard/google/daisy/Kconfig index f15bd9b864..61bb80b3a8 100644 --- a/src/mainboard/google/daisy/Kconfig +++ b/src/mainboard/google/daisy/Kconfig @@ -58,4 +58,8 @@ config UART_FOR_CONSOLE int default 3 +config PMIC_BUS + int + default 0 + endif # BOARD_GOOGLE_DAISY diff --git a/src/mainboard/google/daisy/romstage.c b/src/mainboard/google/daisy/romstage.c index 838a6c70d7..08570249e8 100644 --- a/src/mainboard/google/daisy/romstage.c +++ b/src/mainboard/google/daisy/romstage.c @@ -36,8 +36,6 @@ #include "exynos5250.h" -#define PMIC_BUS 0 - static void setup_power(int is_resume) { int error = 0; @@ -63,26 +61,26 @@ static void setup_power(int is_resume) * * Disable Coin BATT Charging */ - error = max77686_disable_backup_batt(PMIC_BUS); + error = max77686_disable_backup_batt(CONFIG_PMIC_BUS); - error |= max77686_volsetting(PMIC_BUS, PMIC_BUCK2, VDD_ARM_MV, + error |= max77686_volsetting(CONFIG_PMIC_BUS, PMIC_BUCK2, VDD_ARM_MV, REG_ENABLE, MAX77686_MV); - error |= max77686_volsetting(PMIC_BUS, PMIC_BUCK3, VDD_INT_UV, + error |= max77686_volsetting(CONFIG_PMIC_BUS, PMIC_BUCK3, VDD_INT_UV, REG_ENABLE, MAX77686_UV); - error |= max77686_volsetting(PMIC_BUS, PMIC_BUCK1, VDD_MIF_MV, + error |= max77686_volsetting(CONFIG_PMIC_BUS, PMIC_BUCK1, VDD_MIF_MV, REG_ENABLE, MAX77686_MV); - error |= max77686_volsetting(PMIC_BUS, PMIC_BUCK4, VDD_G3D_MV, + error |= max77686_volsetting(CONFIG_PMIC_BUS, PMIC_BUCK4, VDD_G3D_MV, REG_ENABLE, MAX77686_MV); - error |= max77686_volsetting(PMIC_BUS, PMIC_LDO2, VDD_LDO2_MV, + error |= max77686_volsetting(CONFIG_PMIC_BUS, PMIC_LDO2, VDD_LDO2_MV, REG_ENABLE, MAX77686_MV); - error |= max77686_volsetting(PMIC_BUS, PMIC_LDO3, VDD_LDO3_MV, + error |= max77686_volsetting(CONFIG_PMIC_BUS, PMIC_LDO3, VDD_LDO3_MV, REG_ENABLE, MAX77686_MV); - error |= max77686_volsetting(PMIC_BUS, PMIC_LDO5, VDD_LDO5_MV, + error |= max77686_volsetting(CONFIG_PMIC_BUS, PMIC_LDO5, VDD_LDO5_MV, REG_ENABLE, MAX77686_MV); - error |= max77686_volsetting(PMIC_BUS, PMIC_LDO10, VDD_LDO10_MV, + error |= max77686_volsetting(CONFIG_PMIC_BUS, PMIC_LDO10, VDD_LDO10_MV, REG_ENABLE, MAX77686_MV); - error |= max77686_enable_32khz_cp(PMIC_BUS); + error |= max77686_enable_32khz_cp(CONFIG_PMIC_BUS); if (error) { printk(BIOS_CRIT, "%s: PMIC error: %#x\n", __func__, error); |