i2c-core error messages

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

On Mon, Mar 06, 2006 at 09:33:56AM +0100, ext Jean Delvare wrote:
> Which version of the i2c-core.c file are you referring to, please? The
> file Linux 2.6.16-rc5 has an i2c_probe function which properly returns
> errors.
>
I have rc5 and I found a problem here
static int i2c_probe_address(struct i2c_adapter *adapter, int addr, int kind, 
			     int (*found_proc) (struct i2c_adapter *,int, int)

---line 664---
if (kind < 0) {
	if (i2c_smbus_xfer(adapter, addr, 0, 0, 0,
		I2C_SMBUS_QUICK, NULL) < 0)
		return 0;
	      }
---
Shouldn't it be something like, or have I misunderstood something here?

if (kind < 0) {
	if ((err = (i2c_smbus_xfer(adapter, addr, 0, 0, 0,
	I2C_SMBUS_QUICK, NULL)) < 0)
	return err;
	      }

Cheers,
Kai




[Index of Archives]     [Linux Kernel]     [Linux Hardware Monitoring]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux