summaryrefslogtreecommitdiffstats
path: root/include/i2c.h
diff options
context:
space:
mode:
authorStefan Roese <sr@denx.de>2007-02-27 21:56:06 +0100
committerStefan Roese <sr@denx.de>2007-02-27 21:56:06 +0100
commit621a7873ef205c4325fc07c646bd1d509763b22f (patch)
tree3e2006c9f3a953532bb6a97d896390f03e58bd03 /include/i2c.h
parent2e46b8fc8c16728ec3a5db2701026bbd1334ecdc (diff)
parent743571145b37182757d4e688a77860b36ee77573 (diff)
downloadu-boot-621a7873ef205c4325fc07c646bd1d509763b22f.tar.gz
u-boot-621a7873ef205c4325fc07c646bd1d509763b22f.tar.xz
u-boot-621a7873ef205c4325fc07c646bd1d509763b22f.zip
Merge with git+ssh://sr@pollux.denx.org/home/sr/git/u-boot/denx/.git
Diffstat (limited to 'include/i2c.h')
-rw-r--r--include/i2c.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/i2c.h b/include/i2c.h
index a8f729afe0..54c6f9fbc6 100644
--- a/include/i2c.h
+++ b/include/i2c.h
@@ -46,6 +46,16 @@
*/
#define I2C_RXTX_LEN 128 /* maximum tx/rx buffer length */
+#if defined(CONFIG_I2C_MULTI_BUS)
+#define CFG_MAX_I2C_BUS 2
+#define I2C_GET_BUS() i2c_get_bus_num()
+#define I2C_SET_BUS(a) i2c_set_bus_num(a)
+#else
+#define CFG_MAX_I2C_BUS 1
+#define I2C_GET_BUS() 0
+#define I2C_SET_BUS(a)
+#endif
+
/*
* Initialization, must be called once on start up, may be called
* repeatedly to change the speed and slave addresses.