diff options
author | Simon Glass <sjg@chromium.org> | 2021-08-08 12:20:27 -0600 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2021-09-04 12:26:02 -0400 |
commit | 9d8665b7091d7d67df7dd31eafe1b54e25f6c3e4 (patch) | |
tree | a433ee15481504deac558c511630d087ec1201b4 /board | |
parent | 29d7153ec384e072755e8951a8a33f29372f925c (diff) | |
download | u-boot-9d8665b7091d7d67df7dd31eafe1b54e25f6c3e4.zip u-boot-9d8665b7091d7d67df7dd31eafe1b54e25f6c3e4.tar.gz u-boot-9d8665b7091d7d67df7dd31eafe1b54e25f6c3e4.tar.bz2 |
i2c: Convert CONFIG_POWER_I2C et al to Kconfig
This converts the following to Kconfig:
CONFIG_POWER_I2C
CONFIG_POWER_LEGACY
They are handled at the same time due to a dependency between them.
Update the Makefile rule to use legacy power only in U-Boot proper.
Unfortunately a separate rule is needed in SPL to be able to build
legacy power. Add SPL related symbols for both, to allow for SPL-only
usage.
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>
[trini: More SPL related cleanups, reword commit message]
Signed-off-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'board')
-rw-r--r-- | board/compulab/cl-som-imx7/cl-som-imx7.c | 4 | ||||
-rw-r--r-- | board/freescale/imx8mp_evk/spl.c | 2 | ||||
-rw-r--r-- | board/freescale/imx8mq_evk/spl.c | 2 | ||||
-rw-r--r-- | board/samsung/common/board.c | 2 | ||||
-rw-r--r-- | board/technexion/pico-imx7d/pico-imx7d.c | 2 | ||||
-rw-r--r-- | board/tqc/tqma6/tqma6.c | 2 | ||||
-rw-r--r-- | board/udoo/neo/neo.c | 2 |
7 files changed, 8 insertions, 8 deletions
diff --git a/board/compulab/cl-som-imx7/cl-som-imx7.c b/board/compulab/cl-som-imx7/cl-som-imx7.c index c54e02f..3ee1335 100644 --- a/board/compulab/cl-som-imx7/cl-som-imx7.c +++ b/board/compulab/cl-som-imx7/cl-som-imx7.c @@ -267,7 +267,7 @@ int board_init(void) return 0; } -#ifdef CONFIG_POWER_LEGACY +#if CONFIG_IS_ENABLED(POWER_LEGACY) #define I2C_PMIC 0 int power_init_board(void) { @@ -293,7 +293,7 @@ int power_init_board(void) return 0; } -#endif /* CONFIG_POWER_LEGACY */ +#endif /* CONFIG_IS_ENABLED(POWER_LEGACY) */ /* * cl_som_imx7_setup_wdog() - watchdog configuration. diff --git a/board/freescale/imx8mp_evk/spl.c b/board/freescale/imx8mp_evk/spl.c index d317f21..eca42c7 100644 --- a/board/freescale/imx8mp_evk/spl.c +++ b/board/freescale/imx8mp_evk/spl.c @@ -63,7 +63,7 @@ struct i2c_pads_info i2c_pad_info1 = { }, }; -#ifdef CONFIG_POWER_LEGACY +#if CONFIG_IS_ENABLED(POWER_LEGACY) #define I2C_PMIC 0 int power_init_board(void) { diff --git a/board/freescale/imx8mq_evk/spl.c b/board/freescale/imx8mq_evk/spl.c index 6ee6230..67d069b 100644 --- a/board/freescale/imx8mq_evk/spl.c +++ b/board/freescale/imx8mq_evk/spl.c @@ -156,7 +156,7 @@ int board_mmc_init(struct bd_info *bis) return 0; } -#ifdef CONFIG_POWER_LEGACY +#if CONFIG_IS_ENABLED(POWER_LEGACY) #define I2C_PMIC 0 int power_init_board(void) { diff --git a/board/samsung/common/board.c b/board/samsung/common/board.c index 08f9202..97791aa 100644 --- a/board/samsung/common/board.c +++ b/board/samsung/common/board.c @@ -185,7 +185,7 @@ int board_early_init_f(void) } #endif -#if defined(CONFIG_POWER_LEGACY) || defined(CONFIG_DM_PMIC) +#if CONFIG_IS_ENABLED(POWER_LEGACY) || CONFIG_IS_ENABLED(DM_PMIC) int power_init_board(void) { set_ps_hold_ctrl(); diff --git a/board/technexion/pico-imx7d/pico-imx7d.c b/board/technexion/pico-imx7d/pico-imx7d.c index 81b1fb3..d97e13b 100644 --- a/board/technexion/pico-imx7d/pico-imx7d.c +++ b/board/technexion/pico-imx7d/pico-imx7d.c @@ -60,7 +60,7 @@ int dram_init(void) return 0; } -#ifdef CONFIG_POWER_LEGACY +#if CONFIG_IS_ENABLED(POWER_LEGACY) #define I2C_PMIC 3 int power_init_board(void) { diff --git a/board/tqc/tqma6/tqma6.c b/board/tqc/tqma6/tqma6.c index f851e19..de9c001 100644 --- a/board/tqc/tqma6/tqma6.c +++ b/board/tqc/tqma6/tqma6.c @@ -247,7 +247,7 @@ static const char *tqma6_get_boardname(void) }; } -#ifdef CONFIG_POWER_LEGACY +#if CONFIG_IS_ENABLED(POWER_LEGACY) /* setup board specific PMIC */ int power_init_board(void) { diff --git a/board/udoo/neo/neo.c b/board/udoo/neo/neo.c index 88889df..ce005d3 100644 --- a/board/udoo/neo/neo.c +++ b/board/udoo/neo/neo.c @@ -96,7 +96,7 @@ static struct i2c_pads_info i2c_pad_info1 = { }; #endif -#ifdef CONFIG_POWER_LEGACY +#if CONFIG_IS_ENABLED(POWER_LEGACY) int power_init_board(void) { struct pmic *p; |