diff mbox

[U-Boot,V3,2/3] i2c:multi_i2c: add new macros I2C_7 and I2C_8

Message ID 1369383791-21795-3-git-send-email-p.wilczek@samsung.com
State Changes Requested
Delegated to: Minkyu Kang
Headers show

Commit Message

Piotr Wilczek May 24, 2013, 8:23 a.m. UTC
This patch add new macros CONFIG_SOFT_I2C_I2C7_SCL/SDA and CONFIG_SOFT_I2C_I2C8_SCL/SDA

Signed-off-by: Piotr Wilczek <p.wilczek@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
CC: Lukasz Majewski <l.majewski@samsung.com>
---
Changes in v3: none
Changes in v2: none
---
 board/samsung/common/multi_i2c.c |   33 +++++++++++++++++++++++++++++++++
 1 file changed, 33 insertions(+)
diff mbox

Patch

diff --git a/board/samsung/common/multi_i2c.c b/board/samsung/common/multi_i2c.c
index d6c3d37..5903be4 100644
--- a/board/samsung/common/multi_i2c.c
+++ b/board/samsung/common/multi_i2c.c
@@ -24,6 +24,31 @@ 
 #include <common.h>
 #include <i2c.h>
 
+#ifndef CONFIG_SOFT_I2C_I2C5_SCL
+#define CONFIG_SOFT_I2C_I2C5_SCL 0
+#endif
+#ifndef CONFIG_SOFT_I2C_I2C7_SCL
+#define CONFIG_SOFT_I2C_I2C7_SCL 0
+#endif
+#ifndef CONFIG_SOFT_I2C_I2C8_SCL
+#define CONFIG_SOFT_I2C_I2C8_SCL 0
+#endif
+#ifndef CONFIG_SOFT_I2C_I2C9_SCL
+#define CONFIG_SOFT_I2C_I2C9_SCL 0
+#endif
+#ifndef CONFIG_SOFT_I2C_I2C5_SDA
+#define CONFIG_SOFT_I2C_I2C5_SDA 0
+#endif
+#ifndef CONFIG_SOFT_I2C_I2C7_SDA
+#define CONFIG_SOFT_I2C_I2C7_SDA 0
+#endif
+#ifndef CONFIG_SOFT_I2C_I2C8_SDA
+#define CONFIG_SOFT_I2C_I2C8_SDA 0
+#endif
+#ifndef CONFIG_SOFT_I2C_I2C9_SDA
+#define CONFIG_SOFT_I2C_I2C9_SDA 0
+#endif
+
 /* Handle multiple I2C buses instances */
 int get_multi_scl_pin(void)
 {
@@ -33,6 +58,10 @@  int get_multi_scl_pin(void)
 	case I2C_0: /* I2C_0 definition - compatibility layer */
 	case I2C_5:
 		return CONFIG_SOFT_I2C_I2C5_SCL;
+	case I2C_7:
+		return CONFIG_SOFT_I2C_I2C7_SCL;
+	case I2C_8:
+		return CONFIG_SOFT_I2C_I2C8_SCL;
 	case I2C_9:
 		return CONFIG_SOFT_I2C_I2C9_SCL;
 	default:
@@ -50,6 +79,10 @@  int get_multi_sda_pin(void)
 	case I2C_0: /* I2C_0 definition - compatibility layer */
 	case I2C_5:
 		return CONFIG_SOFT_I2C_I2C5_SDA;
+	case I2C_7:
+		return CONFIG_SOFT_I2C_I2C7_SDA;
+	case I2C_8:
+		return CONFIG_SOFT_I2C_I2C8_SDA;
 	case I2C_9:
 		return CONFIG_SOFT_I2C_I2C9_SDA;
 	default: