i2c-dev: Clarify the unit of ioctl I2C_TIMEOUT
The unit in which user-space can set the bus timeout value is jiffies for historical reasons (back when HZ was always 100.) This is however not good because user-space doesn't know how long a jiffy lasts. The timeout value should instead be set in a fixed time unit. Given the original value of HZ, this unit should be 10 ms, for compatibility. Signed-off-by: Jean Delvare <khali@linux-fr.org> Acked-by: Wolfram Sang <w.sang@pengutronix.de>
This commit is contained in:
@ -33,7 +33,7 @@
|
||||
*/
|
||||
#define I2C_RETRIES 0x0701 /* number of times a device address should
|
||||
be polled when not acknowledging */
|
||||
#define I2C_TIMEOUT 0x0702 /* set timeout in jiffies - call with int */
|
||||
#define I2C_TIMEOUT 0x0702 /* set timeout in units of 10 ms */
|
||||
|
||||
/* NOTE: Slave address is 7 or 10 bits, but 10-bit addresses
|
||||
* are NOT supported! (due to code brokenness)
|
||||
|
Reference in New Issue
Block a user