diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2014-11-07 16:16:31 +1100 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2014-11-07 16:16:31 +1100 |
commit | 2b6b701f1dd15a4f0e39d51d048b90ea729ecc75 (patch) | |
tree | ef0179308240cb519c79309169adf85cde03ffab /include/i2c.h | |
parent | cd3ff93ad228c25330878db021ec30ca97638e2d (diff) | |
download | skiboot-2b6b701f1dd15a4f0e39d51d048b90ea729ecc75.zip skiboot-2b6b701f1dd15a4f0e39d51d048b90ea729ecc75.tar.gz skiboot-2b6b701f1dd15a4f0e39d51d048b90ea729ecc75.tar.bz2 |
i2c: Rework P8 i2c driver
This updates the i2c driver significantly, using a simpler state machine,
using the new timer for timeouts, and fixing a number of issues. I also
changed the Linux interface so I've changed the token number since some
builds have been done with the old code already.
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'include/i2c.h')
-rw-r--r-- | include/i2c.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/i2c.h b/include/i2c.h index 921a9dd..af88ba0 100644 --- a/include/i2c.h +++ b/include/i2c.h @@ -25,11 +25,12 @@ struct i2c_bus { int (*queue_req)(struct i2c_bus *bus, struct i2c_request *req); struct i2c_request *(*alloc_req)(struct i2c_bus *bus); - void (*dealloc_req)(struct i2c_request *req); + void (*free_req)(struct i2c_request *req); }; struct i2c_request { struct list_node link; + struct i2c_bus *bus; enum i2c_operation { I2C_READ, /* RAW read from the device without offset */ I2C_WRITE, /* RAW write to the device without offset */ |