mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
i2c-algo-bit: Add pre- and post-xfer hooks
Drivers might have to do random things before and/or after I2C transfers. Add hooks to the i2c-algo-bit implementation to let them do so. Signed-off-by: Jean Delvare <khali@linux-fr.org> Cc: Alex Deucher <alexdeucher@gmail.com>
This commit is contained in:
parent
d07b56b309
commit
0a9c147513
2 changed files with 11 additions and 0 deletions
|
@ -36,6 +36,8 @@ struct i2c_algo_bit_data {
|
|||
void (*setscl) (void *data, int state);
|
||||
int (*getsda) (void *data);
|
||||
int (*getscl) (void *data);
|
||||
int (*pre_xfer) (struct i2c_adapter *);
|
||||
void (*post_xfer) (struct i2c_adapter *);
|
||||
|
||||
/* local settings */
|
||||
int udelay; /* half clock cycle time in us,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue