[U-Boot] [PATCH V3 05/13] i2c: Create common default i2c_set_bus_num() function
Stefano Babic
sbabic at denx.de
Mon Oct 10 12:50:12 CEST 2011
New default, weak i2c_set_bus_num() function.
Signed-off-by: Stefano Babic <sbabic at denx.de>
Cc: Heiko Schocher <hs at denx.de>
---
Changes since V2:
- codestyling: drop newline (Heiko Schocher)
Changes since V1:
- add a weak function i2c_set_bus_num() to cmd_i2c.c instead of adding a
dummy function to mxc_i2c.c. (Heiko Schocher)
common/cmd_i2c.c | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/common/cmd_i2c.c b/common/cmd_i2c.c
index 3ea75f7..8baa541 100644
--- a/common/cmd_i2c.c
+++ b/common/cmd_i2c.c
@@ -158,6 +158,13 @@ int __def_i2c_set_bus_speed(unsigned int speed)
int i2c_set_bus_speed(unsigned int)
__attribute__((weak, alias("__def_i2c_set_bus_speed")));
+int __def_i2c_set_bus_num(unsigned int bus)
+{
+ return 0;
+}
+int i2c_set_bus_num(unsigned int)
+ __attribute__((weak, alias("__def_i2c_set_bus_num")));
+
/*
* get_alen: small parser helper function to get address length
* returns the address length
--
1.7.1
More information about the U-Boot
mailing list