From 85d05fb3fde692fdaa6b1f84c33fee718abebf0f Mon Sep 17 00:00:00 2001 From: Jarkko Nikula Date: Wed, 7 Nov 2007 06:54:31 +0200 Subject: ARM: OMAP: Add helper module for board specific I2C bus registration This helper module simplifies I2C bus registration for different OMAP platforms by doing registration in one place only and to allow board specific bus configuration like clock rate and number of busses configured. Helper should cover OMAP processors from first to third generation. This patch just adds the feature and current implementation cleanup and board file modifications will be done in following patches. Signed-off-by: Jarkko Nikula Acked-by: David Brownell Signed-off-by: Tony Lindgren --- include/asm-arm/arch-omap/common.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'include/asm-arm/arch-omap/common.h') diff --git a/include/asm-arm/arch-omap/common.h b/include/asm-arm/arch-omap/common.h index 08d58abd821..442aecbb8f4 100644 --- a/include/asm-arm/arch-omap/common.h +++ b/include/asm-arm/arch-omap/common.h @@ -27,10 +27,21 @@ #ifndef __ARCH_ARM_MACH_OMAP_COMMON_H #define __ARCH_ARM_MACH_OMAP_COMMON_H +#ifdef CONFIG_I2C_OMAP +#include +#endif + struct sys_timer; extern void omap_map_common_io(void); extern struct sys_timer omap_timer; extern void omap_serial_init(void); +#ifdef CONFIG_I2C_OMAP +extern int omap_register_i2c_bus(int bus_id, u32 clkrate, + struct i2c_board_info const *info, + unsigned len); +#else +#define omap_register_i2c_bus(a, b, c, d) 0 +#endif #endif /* __ARCH_ARM_MACH_OMAP_COMMON_H */ -- cgit v1.2.3-70-g09d2