Skip to content

Commit 877a50b

Browse files
YueHaibingpavelmachek
authored andcommitted
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 4c3718f ("leds: bd2802: Convert to use GPIO descriptors") left behind this unused variable. Signed-off-by: YueHaibing <[email protected]> Reviewed-by: Linus Walleij <[email protected]> Signed-off-by: Pavel Machek <[email protected]>
1 parent ccbbb11 commit 877a50b

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

drivers/leds/leds-bd2802.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -660,15 +660,13 @@ static int bd2802_probe(struct i2c_client *client,
660660
const struct i2c_device_id *id)
661661
{
662662
struct bd2802_led *led;
663-
struct bd2802_led_platform_data *pdata;
664663
int ret, i;
665664

666665
led = devm_kzalloc(&client->dev, sizeof(struct bd2802_led), GFP_KERNEL);
667666
if (!led)
668667
return -ENOMEM;
669668

670669
led->client = client;
671-
pdata = led->pdata = dev_get_platdata(&client->dev);
672670
i2c_set_clientdata(client, led);
673671

674672
/*

0 commit comments

Comments
 (0)