I'd like to write an I2C driver for a sensor device. There is a non-zero conversion time, and I don't want to waste kernel time to wait and poll busy state until the device is busy.
I thought I setup a timer and call the update time to time.
However the whole system freezes when execution reaches any I2C function.
I prepared a really simplified example, which is not working. Everything fine until the I2C access.
Without I2C stuff, the code works. Without the timer stuff, I2C works.
I did not find how to use I2C in an asynchronous (non-blocking) manner.