Skip to contentSkip to conversation

svn commit: r4435 - lm-sensors/trunk/prog/py-smbus

lm-sensors Jean Delvare 2 participants 2 messages Jun 10, 2007 – Jun 14, 2007

lore
Share & tools
lore
#0 lore raw
Quoted 11 lines · On Sat, 9 Jun 2007 18:19:45 +0200 (CEST), [email protected]…
      Author: mmh
        Date: Sat Jun  9 18:19:37 2007

New Revision: 4435
Changeset: http://lm-sensors.org/changeset/4435

Modified:
lm-sensors/trunk/prog/py-smbus/smbusmodule.c

Log:
Allow i2c block transfers with of length < 32 on kernels that support it.

Review

Quoted 3 lines
(quoted diff) +1 -0
 	if (i2c_smbus_access(self->fd, I2C_SMBUS_READ, (__u8)cmd,
+				len = 32 ? I2C_SMBUS_I2C_BLOCK_BROKEN:
 				I2C_SMBUS_I2C_BLOCK_DATA, &data)) {

This looks wrong to me, should be "len = 32"?

Signature · 6 lines
Jean Delvare

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
#1 lore raw

Hi Jean:

Quoted 9 lines · Jean Delvare
Quoted 8 lines · On Sat, 9 Jun 2007 18:19:45 +0200 (CEST), [email protected]…
      Author: mmh
        Date: Sat Jun  9 18:19:37 2007

New Revision: 4435
Changeset: http://lm-sensors.org/changeset/4435

Modified:
lm-sensors/trunk/prog/py-smbus/smbusmodule.c

Quoted 8 lines

Review

Quoted 6 lines

Log:
Allow i2c block transfers with of length < 32 on kernels that support it.

(quoted diff) +1 -0
 	if (i2c_smbus_access(self->fd, I2C_SMBUS_READ, (__u8)cmd,
+				len = 32 ? I2C_SMBUS_I2C_BLOCK_BROKEN:
 				I2C_SMBUS_I2C_BLOCK_DATA, &data)) {

This looks wrong to me, should be "len = 32"?

Yep, fixed. Thanks.

Signature · 8 lines
Mark M. Hoffman
[email protected]


_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors