diff options
Diffstat (limited to 'include/linux/i2c.h')
-rw-r--r-- | include/linux/i2c.h | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/include/linux/i2c.h b/include/linux/i2c.h index 526ddc8eecf..9b5d04768c2 100644 --- a/include/linux/i2c.h +++ b/include/linux/i2c.h | |||
@@ -64,14 +64,6 @@ extern int i2c_master_recv(struct i2c_client *,char* ,int); | |||
64 | */ | 64 | */ |
65 | extern int i2c_transfer(struct i2c_adapter *adap, struct i2c_msg *msgs, int num); | 65 | extern int i2c_transfer(struct i2c_adapter *adap, struct i2c_msg *msgs, int num); |
66 | 66 | ||
67 | /* | ||
68 | * Some adapter types (i.e. PCF 8584 based ones) may support slave behaviuor. | ||
69 | * This is not tested/implemented yet and will change in the future. | ||
70 | */ | ||
71 | extern int i2c_slave_send(struct i2c_client *,char*,int); | ||
72 | extern int i2c_slave_recv(struct i2c_client *,char*,int); | ||
73 | |||
74 | |||
75 | 67 | ||
76 | /* This is the very generalized SMBus access routine. You probably do not | 68 | /* This is the very generalized SMBus access routine. You probably do not |
77 | want to use this, though; one of the functions below may be much easier, | 69 | want to use this, though; one of the functions below may be much easier, |
@@ -193,16 +185,14 @@ struct i2c_algorithm { | |||
193 | to NULL. If an adapter algorithm can do SMBus access, set | 185 | to NULL. If an adapter algorithm can do SMBus access, set |
194 | smbus_xfer. If set to NULL, the SMBus protocol is simulated | 186 | smbus_xfer. If set to NULL, the SMBus protocol is simulated |
195 | using common I2C messages */ | 187 | using common I2C messages */ |
188 | /* master_xfer should return the number of messages successfully | ||
189 | processed, or a negative value on error */ | ||
196 | int (*master_xfer)(struct i2c_adapter *adap,struct i2c_msg *msgs, | 190 | int (*master_xfer)(struct i2c_adapter *adap,struct i2c_msg *msgs, |
197 | int num); | 191 | int num); |
198 | int (*smbus_xfer) (struct i2c_adapter *adap, u16 addr, | 192 | int (*smbus_xfer) (struct i2c_adapter *adap, u16 addr, |
199 | unsigned short flags, char read_write, | 193 | unsigned short flags, char read_write, |
200 | u8 command, int size, union i2c_smbus_data * data); | 194 | u8 command, int size, union i2c_smbus_data * data); |
201 | 195 | ||
202 | /* --- these optional/future use for some adapter types.*/ | ||
203 | int (*slave_send)(struct i2c_adapter *,char*,int); | ||
204 | int (*slave_recv)(struct i2c_adapter *,char*,int); | ||
205 | |||
206 | /* --- ioctl like call to set div. parameters. */ | 196 | /* --- ioctl like call to set div. parameters. */ |
207 | int (*algo_control)(struct i2c_adapter *, unsigned int, unsigned long); | 197 | int (*algo_control)(struct i2c_adapter *, unsigned int, unsigned long); |
208 | 198 | ||
@@ -218,7 +208,7 @@ struct i2c_adapter { | |||
218 | struct module *owner; | 208 | struct module *owner; |
219 | unsigned int id; | 209 | unsigned int id; |
220 | unsigned int class; | 210 | unsigned int class; |
221 | struct i2c_algorithm *algo;/* the algorithm to access the bus */ | 211 | const struct i2c_algorithm *algo; /* the algorithm to access the bus */ |
222 | void *algo_data; | 212 | void *algo_data; |
223 | 213 | ||
224 | /* --- administration stuff. */ | 214 | /* --- administration stuff. */ |