diff options
author | Jean Delvare <khali@linux-fr.org> | 2010-03-02 06:23:40 -0500 |
---|---|---|
committer | Jean Delvare <khali@linux-fr.org> | 2010-03-02 06:23:40 -0500 |
commit | c05d490234b7cf1715d9568d2041d9bc598a0b45 (patch) | |
tree | 6bc16bff57c044834563cc46a9528ceea54ad6f5 /drivers/i2c/busses/i2c-tiny-usb.c | |
parent | 393764340beb595c1ad7dd2d2243c2b6551aaa71 (diff) |
i2c-tiny-usb: Fix a comment on bus frequency
The description of the delay parameter is incomplete, it suggests that
there is a direct relation between the delay value and the bus
frequency. In fact, due to additional delays in the i2c bitbanging
code, the i2c clock is always much slower.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Till Harbaum <Till@Harbaum.org>
Diffstat (limited to 'drivers/i2c/busses/i2c-tiny-usb.c')
-rw-r--r-- | drivers/i2c/busses/i2c-tiny-usb.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/i2c/busses/i2c-tiny-usb.c b/drivers/i2c/busses/i2c-tiny-usb.c index 41adb390e49c..b5b1bbf37d3c 100644 --- a/drivers/i2c/busses/i2c-tiny-usb.c +++ b/drivers/i2c/busses/i2c-tiny-usb.c | |||
@@ -31,11 +31,13 @@ | |||
31 | #define CMD_I2C_IO_BEGIN (1<<0) | 31 | #define CMD_I2C_IO_BEGIN (1<<0) |
32 | #define CMD_I2C_IO_END (1<<1) | 32 | #define CMD_I2C_IO_END (1<<1) |
33 | 33 | ||
34 | /* i2c bit delay, default is 10us -> 100kHz */ | 34 | /* i2c bit delay, default is 10us -> 100kHz max |
35 | (in practice, due to additional delays in the i2c bitbanging | ||
36 | code this results in a i2c clock of about 50kHz) */ | ||
35 | static unsigned short delay = 10; | 37 | static unsigned short delay = 10; |
36 | module_param(delay, ushort, 0); | 38 | module_param(delay, ushort, 0); |
37 | MODULE_PARM_DESC(delay, "bit delay in microseconds, " | 39 | MODULE_PARM_DESC(delay, "bit delay in microseconds " |
38 | "e.g. 10 for 100kHz (default is 100kHz)"); | 40 | "(default is 10us for 100kHz max)"); |
39 | 41 | ||
40 | static int usb_read(struct i2c_adapter *adapter, int cmd, | 42 | static int usb_read(struct i2c_adapter *adapter, int cmd, |
41 | int value, int index, void *data, int len); | 43 | int value, int index, void *data, int len); |