[PATCH 139/149] librem5: Rename CONFIG_POWER_BD71837 symbols
Tom Rini
trini at konsulko.com
Sun Dec 4 16:14:10 CET 2022
Rename the CONFIG_POWER_BD71837_I2C_* symbols to not have the CONFIG
prefix and be local to the file they are used in.
Signed-off-by: Tom Rini <trini at konsulko.com>
---
board/purism/librem5/spl.c | 8 +++++---
include/configs/librem5.h | 4 ----
2 files changed, 5 insertions(+), 7 deletions(-)
diff --git a/board/purism/librem5/spl.c b/board/purism/librem5/spl.c
index 1bfd948806f2..1a203b459990 100644
--- a/board/purism/librem5/spl.c
+++ b/board/purism/librem5/spl.c
@@ -322,6 +322,8 @@ void disable_charger_bq25895(void)
}
#define I2C_PMIC 0
+#define POWER_BD71837_I2C_BUS 0
+#define POWER_BD71837_I2C_ADDR 0x4B
int power_bd71837_init(unsigned char bus)
{
@@ -336,7 +338,7 @@ int power_bd71837_init(unsigned char bus)
p->name = name;
p->interface = I2C_PMIC;
p->number_of_regs = BD718XX_MAX_REGISTER;
- p->hw.i2c.addr = CONFIG_POWER_BD71837_I2C_ADDR;
+ p->hw.i2c.addr = POWER_BD71837_I2C_ADDR;
p->hw.i2c.tx_num = 1;
p->bus = bus;
@@ -357,10 +359,10 @@ int power_init_board(void)
/*
* Init PMIC
*/
- rv = power_bd71837_init(CONFIG_POWER_BD71837_I2C_BUS);
+ rv = power_bd71837_init(POWER_BD71837_I2C_BUS);
if (rv) {
log_err("%s: power_bd71837_init(%d) error %d\n", __func__,
- CONFIG_POWER_BD71837_I2C_BUS, rv);
+ POWER_BD71837_I2C_BUS, rv);
goto out;
}
diff --git a/include/configs/librem5.h b/include/configs/librem5.h
index 9e4d373e56d5..e17190ce9c5d 100644
--- a/include/configs/librem5.h
+++ b/include/configs/librem5.h
@@ -19,10 +19,6 @@
#define CONFIG_SPL_ABORT_ON_RAW_IMAGE /* For RAW image gives a error info not panic */
-#define CONFIG_POWER_BD71837
-#define CONFIG_POWER_BD71837_I2C_BUS 0
-#define CONFIG_POWER_BD71837_I2C_ADDR 0x4B
-
#endif /* CONFIG_SPL_BUILD*/
#define CFG_SYS_FSL_USDHC_NUM 2
--
2.25.1
More information about the U-Boot
mailing list