diff options
author | Wolfram Sang <wsa+renesas@sang-engineering.com> | 2019-06-08 12:55:44 +0200 |
---|---|---|
committer | Jacek Anaszewski <jacek.anaszewski@gmail.com> | 2019-06-09 13:11:44 +0200 |
commit | 09bfa5f6833a62bd6669d3ba7f83105181287b92 (patch) | |
tree | cd48533eeeeaacffbf016fe69e6eef15d346dc18 /drivers | |
parent | 1c57d9bd29f63996b301fe92190713e39730d6ca (diff) | |
download | linux-09bfa5f6833a62bd6669d3ba7f83105181287b92.tar.gz linux-09bfa5f6833a62bd6669d3ba7f83105181287b92.tar.bz2 linux-09bfa5f6833a62bd6669d3ba7f83105181287b92.zip |
leds: leds-tca6507: 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>
Acked-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Jacek Anaszewski <jacek.anaszewski@gmail.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/leds/leds-tca6507.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/leds/leds-tca6507.c b/drivers/leds/leds-tca6507.c index 8f343afa4787..0352265b3c79 100644 --- a/drivers/leds/leds-tca6507.c +++ b/drivers/leds/leds-tca6507.c @@ -757,7 +757,7 @@ static int tca6507_probe(struct i2c_client *client, int err; int i = 0; - adapter = to_i2c_adapter(client->dev.parent); + adapter = client->adapter; pdata = dev_get_platdata(&client->dev); if (!i2c_check_functionality(adapter, I2C_FUNC_I2C)) |