Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

misc: tsl2550: simplify getting the adapter of a client

We have a dedicated pointer for that, so use it. Much easier to read and
less computation involved.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Wolfram Sang and committed by
Greg Kroah-Hartman
3cc2decc 1a0911a0

+1 -1
+1 -1
drivers/misc/tsl2550.c
··· 336 336 static int tsl2550_probe(struct i2c_client *client, 337 337 const struct i2c_device_id *id) 338 338 { 339 - struct i2c_adapter *adapter = to_i2c_adapter(client->dev.parent); 339 + struct i2c_adapter *adapter = client->adapter; 340 340 struct tsl2550_data *data; 341 341 int *opmode, err = 0; 342 342