/* ----------------------------------------------------------------------- */
struct adv7175 {
- unsigned char reg[128];
-
int norm;
int input;
int enable;
u8 reg,
u8 value)
{
- struct adv7175 *encoder = i2c_get_clientdata(client);
-
- encoder->reg[reg] = value;
return i2c_smbus_write_byte_data(client, reg, value);
}
* the adapter understands raw I2C */
if (i2c_check_functionality(client->adapter, I2C_FUNC_I2C)) {
/* do raw I2C, not smbus compatible */
- struct adv7175 *encoder = i2c_get_clientdata(client);
struct i2c_msg msg;
u8 block_data[32];
msg.len = 0;
block_data[msg.len++] = reg = data[0];
do {
- block_data[msg.len++] =
- encoder->reg[reg++] = data[1];
+ block_data[msg.len++] = data[1];
+ reg++;
len -= 2;
data += 2;
} while (len >= 2 && data[0] == reg &&