Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0-only */
0002 /*
0003  * Helper module for board specific I2C bus registration
0004  *
0005  * Copyright (C) 2009 Nokia Corporation.
0006  */
0007 
0008 #ifndef __ARCH_ARM_MACH_OMAP1_I2C_H
0009 #define __ARCH_ARM_MACH_OMAP1_I2C_H
0010 
0011 struct i2c_board_info;
0012 struct omap_i2c_bus_platform_data;
0013 
0014 int omap_i2c_add_bus(struct omap_i2c_bus_platform_data *i2c_pdata,
0015             int bus_id);
0016 
0017 #if defined(CONFIG_I2C_OMAP) || defined(CONFIG_I2C_OMAP_MODULE)
0018 extern int omap_register_i2c_bus(int bus_id, u32 clkrate,
0019                  struct i2c_board_info const *info,
0020                  unsigned len);
0021 extern int omap_register_i2c_bus_cmdline(void);
0022 #else
0023 static inline int omap_register_i2c_bus(int bus_id, u32 clkrate,
0024                  struct i2c_board_info const *info,
0025                  unsigned len)
0026 {
0027     return 0;
0028 }
0029 
0030 static inline int omap_register_i2c_bus_cmdline(void)
0031 {
0032     return 0;
0033 }
0034 #endif
0035 
0036 #endif /* __ARCH_ARM_MACH_OMAP1_I2C_H */