From da521387a4bde11f83b1f5b79bba0b0c30c7e5d9 Mon Sep 17 00:00:00 2001 From: Stefano Babic Date: Thu, 15 Mar 2012 04:01:42 +0000 Subject: [PATCH] OMAP3: SPL: do not call I2C init if no I2C is set. Call i2c initialization in spl_board_init only if I2C is configured for the board. Signed-off-by: Stefano Babic CC: Tom Rini CC: Wolfgang Denk CC: Simon Schwarz --- arch/arm/cpu/armv7/omap3/board.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm/cpu/armv7/omap3/board.c b/arch/arm/cpu/armv7/omap3/board.c index aabc651413..1fee574364 100644 --- a/arch/arm/cpu/armv7/omap3/board.c +++ b/arch/arm/cpu/armv7/omap3/board.c @@ -92,7 +92,9 @@ u32 omap_boot_device(void) void spl_board_init(void) { +#ifdef CONFIG_SPL_I2C_SUPPORT i2c_init(CONFIG_SYS_I2C_SPEED, CONFIG_SYS_I2C_SLAVE); +#endif } #endif /* CONFIG_SPL_BUILD */ -- 2.25.1