zynq-common: Define CONFIG_SYS_I2C_ZYNQ based on board config

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>
This commit is contained in:
Siva Durga Prasad Paladugu 2015-10-28 11:19:08 +05:30 committed by Michal Simek
parent 83bf005710
commit 1c3f2c7270
1 changed files with 3 additions and 0 deletions

View File

@ -179,7 +179,10 @@
# 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