0001
0002
0003
0004 #ifndef _MLXSW_I2C_H
0005 #define _MLXSW_I2C_H
0006
0007 #include <linux/i2c.h>
0008
0009 #if IS_ENABLED(CONFIG_MLXSW_I2C)
0010
0011 int mlxsw_i2c_driver_register(struct i2c_driver *i2c_driver);
0012 void mlxsw_i2c_driver_unregister(struct i2c_driver *i2c_driver);
0013
0014 #else
0015
0016 static inline int
0017 mlxsw_i2c_driver_register(struct i2c_driver *i2c_driver)
0018 {
0019 return -ENODEV;
0020 }
0021
0022 static inline void
0023 mlxsw_i2c_driver_unregister(struct i2c_driver *i2c_driver)
0024 {
0025 }
0026
0027 #endif
0028
0029 #endif