Lines Matching refs:client
78 static int w83l785ts_probe(struct i2c_client *client,
80 static int w83l785ts_detect(struct i2c_client *client,
82 static int w83l785ts_remove(struct i2c_client *client);
83 static u8 w83l785ts_read_value(struct i2c_client *client, u8 reg, u8 defval);
142 static int w83l785ts_detect(struct i2c_client *client, in w83l785ts_detect() argument
145 struct i2c_adapter *adapter = client->adapter; in w83l785ts_detect()
153 if ((w83l785ts_read_value(client, W83L785TS_REG_CONFIG, 0) & 0x80) in w83l785ts_detect()
154 || (w83l785ts_read_value(client, W83L785TS_REG_TYPE, 0) & 0xFC)) { in w83l785ts_detect()
157 client->addr); in w83l785ts_detect()
162 man_id = (w83l785ts_read_value(client, W83L785TS_REG_MAN_ID1, 0) << 8) in w83l785ts_detect()
163 + w83l785ts_read_value(client, W83L785TS_REG_MAN_ID2, 0); in w83l785ts_detect()
164 chip_id = w83l785ts_read_value(client, W83L785TS_REG_CHIP_ID, 0); in w83l785ts_detect()
179 static int w83l785ts_probe(struct i2c_client *client, in w83l785ts_probe() argument
183 struct device *dev = &client->dev; in w83l785ts_probe()
190 i2c_set_clientdata(client, data); in w83l785ts_probe()
221 static int w83l785ts_remove(struct i2c_client *client) in w83l785ts_remove() argument
223 struct w83l785ts_data *data = i2c_get_clientdata(client); in w83l785ts_remove()
226 device_remove_file(&client->dev, in w83l785ts_remove()
228 device_remove_file(&client->dev, in w83l785ts_remove()
234 static u8 w83l785ts_read_value(struct i2c_client *client, u8 reg, u8 defval) in w83l785ts_read_value() argument
244 if (i2c_get_clientdata(client)) { in w83l785ts_read_value()
245 dev = &client->dev; in w83l785ts_read_value()
248 dev = &client->adapter->dev; in w83l785ts_read_value()
258 value = i2c_smbus_read_byte_data(client, reg); in w83l785ts_read_value()
275 struct i2c_client *client = to_i2c_client(dev); in w83l785ts_update_device() local
276 struct w83l785ts_data *data = i2c_get_clientdata(client); in w83l785ts_update_device()
281 dev_dbg(&client->dev, "Updating w83l785ts data.\n"); in w83l785ts_update_device()
282 data->temp[0] = w83l785ts_read_value(client, in w83l785ts_update_device()
284 data->temp[1] = w83l785ts_read_value(client, in w83l785ts_update_device()