summary refs log tree commit diff
path: root/drivers/leds
diff options
context:
space:
mode:
authorYueHaibing <yuehaibing@huawei.com>2020-01-08 01:53:22 +0000
committerPavel Machek <pavel@ucw.cz>2020-02-26 14:34:55 +0100
commit877a50b8729994a701aac7b2092381bad2c6c145 (patch)
treeed509cb91d84401e37373d4fadac3b28c1883831 /drivers/leds
parentccbbb117c17eaf108216830bdd1e85a551ccc031 (diff)
downloadlinux-877a50b8729994a701aac7b2092381bad2c6c145.tar.gz
leds: leds-bd2802: remove set but not used variable 'pdata'
Fixes gcc '-Wunused-but-set-variable' warning:

drivers/leds/leds-bd2802.c: In function 'bd2802_probe':
drivers/leds/leds-bd2802.c:663:35: warning:
 variable 'pdata' set but not used [-Wunused-but-set-variable]

commit 4c3718f9d6a6 ("leds: bd2802: Convert to use GPIO descriptors")
left behind this unused variable.

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Pavel Machek <pavel@ucw.cz>
Diffstat (limited to 'drivers/leds')
-rw-r--r--drivers/leds/leds-bd2802.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/leds/leds-bd2802.c b/drivers/leds/leds-bd2802.c
index bd61a823d0ca..8bbaef5a2986 100644
--- a/drivers/leds/leds-bd2802.c
+++ b/drivers/leds/leds-bd2802.c
@@ -660,7 +660,6 @@ static int bd2802_probe(struct i2c_client *client,
 			const struct i2c_device_id *id)
 {
 	struct bd2802_led *led;
-	struct bd2802_led_platform_data *pdata;
 	int ret, i;
 
 	led = devm_kzalloc(&client->dev, sizeof(struct bd2802_led), GFP_KERNEL);
@@ -668,7 +667,6 @@ static int bd2802_probe(struct i2c_client *client,
 		return -ENOMEM;
 
 	led->client = client;
-	pdata = led->pdata = dev_get_platdata(&client->dev);
 	i2c_set_clientdata(client, led);
 
 	/*