/* if everything went ok (i.e. 1 msg transmitted), return #bytes * transmitted, else error code. */ return (ret == 1 )? count : ret; } else { dev_err(&client->adapter->dev, "I2C level transfers not supported\n"); return -ENOSYS; } 
/* If everything went ok (i.e. 1 msg transmitted), return #bytes transmitted, else error code. */ return (ret == 1) ? count : ret; 
int i2c_master_send(struct i2c_client *client,const char *buf ,int count){	int ret;	struct i2c_adapter *adap=client->adapter;	struct i2c_msg msg;	if (client->adapter->algo->master_xfer) {		msg.addr   = client->addr;		msg.flags = client->flags & I2C_M_TEN;		msg.len = count;		msg.buf = (char *)buf;			dev_dbg(&client->adapter->dev, "master_send: writing %d bytes.\n",			count);			down(&adap->bus_lock);		ret = adap->algo->master_xfer(adap,&msg,1);		up(&adap->bus_lock);		/* if everything went ok (i.e. 1 msg transmitted), return #bytes		 * transmitted, else error code.		 */		return (ret == 1 )? count : ret;	} else {		dev_err(&client->adapter->dev, "I2C level transfers not supported\n");		return -ENOSYS;	}}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/815f55f280fb2781ba1c2a350516b73e55119c60/i2c-core.c/buggy/drivers/i2c/i2c-core.c