Lines Matching refs:client
31 struct i2c_client *client; member
75 struct i2c_client *client; in saa7191_attach() local
77 client = kmalloc(sizeof(*client), GFP_KERNEL); in saa7191_attach()
78 if (!client) in saa7191_attach()
85 client->data = decoder; in saa7191_attach()
86 client->adapter = adap; in saa7191_attach()
87 client->addr = addr; in saa7191_attach()
88 client->driver = &i2c_driver_saa7191; in saa7191_attach()
89 strcpy(client->name, "saa7191 client"); in saa7191_attach()
90 decoder->client = client; in saa7191_attach()
92 err = i2c_attach_client(client); in saa7191_attach()
106 err = i2c_master_send(client, initseq, sizeof(initseq)); in saa7191_attach()
116 kfree(client); in saa7191_attach()
129 static int saa7191_detach(struct i2c_client *client) in saa7191_detach() argument
131 struct saa7191 *decoder = client->data; in saa7191_detach()
133 i2c_detach_client(client); in saa7191_detach()
135 kfree(client); in saa7191_detach()
140 static unsigned char saa7191_read(struct i2c_client *client, in saa7191_read() argument
143 return ((struct saa7191 *)client->data)->reg[command]; in saa7191_read()
146 static int saa7191_write(struct i2c_client *client, unsigned char command, in saa7191_write() argument
149 ((struct saa7191 *)client->data)->reg[command] = value; in saa7191_write()
150 return i2c_smbus_write_byte_data(client, command, value); in saa7191_write()
153 static int vino_set_input(struct i2c_client *client, int val) in vino_set_input() argument
155 unsigned char luma = saa7191_read(client, SAA7191_REG_LUMA); in vino_set_input()
156 unsigned char iock = saa7191_read(client, SAA7191_REG_IOCK); in vino_set_input()
172 saa7191_write(client, SAA7191_REG_LUMA, luma); in vino_set_input()
173 saa7191_write(client, SAA7191_REG_IOCK, iock); in vino_set_input()
178 static int saa7191_command(struct i2c_client *client, unsigned int cmd, in saa7191_command() argument
181 struct saa7191 *decoder = client->data; in saa7191_command()
190 cap->inputs = (client->adapter->id == VINO_ADAPTER) ? 2 : 1; in saa7191_command()
199 status = i2c_smbus_read_byte_data(client, SAA7191_REG_STATUS); in saa7191_command()
239 switch (client->adapter->id) { in saa7191_command()
241 return vino_set_input(client, *iarg); in saa7191_command()
268 i2c_smbus_write_byte_data(client, XXX, val); in saa7191_command()
273 i2c_smbus_write_byte_data(client, XXX, val); in saa7191_command()
278 i2c_smbus_write_byte_data(client, XXX, val); in saa7191_command()
284 i2c_smbus_write_byte_data(client, SAA7191_REG_HUEC, in saa7191_command()