]> git.sur5r.net Git - u-boot/commitdiff
zynq-common: Define CONFIG_SYS_I2C_ZYNQ based on board config
authorSiva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Wed, 28 Oct 2015 05:49:08 +0000 (11:19 +0530)
committerMichal Simek <michal.simek@xilinx.com>
Wed, 4 Nov 2015 13:49:51 +0000 (14:49 +0100)
Enable CONFIG_SYS_I2C_ZYNQ only if it has either I2C0 or I2C1
enabled in a board config.This fixes the issue of i2c error
during board init if board specific doesnt have either I2C0
or I2C1.

Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
include/configs/zynq-common.h

index ca5ef04302347a27fb17d722227b4561ba3b6f65..2d98cd27a9860727a5351aa5c958dbfec5a68635 100644 (file)
 # define CONFIG_CMD_FS_GENERIC
 #endif
 
+#if defined(CONFIG_ZYNQ_I2C0) || defined(CONFIG_ZYNQ_I2C1)
 #define CONFIG_SYS_I2C_ZYNQ
+#endif
+
 /* I2C */
 #if defined(CONFIG_SYS_I2C_ZYNQ)
 # define CONFIG_CMD_I2C