leds: gpio: Remove unneeded assignment
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Mon, 16 Oct 2023 16:10:04 +0000 (19:10 +0300)
committerLee Jones <lee@kernel.org>
Wed, 1 Nov 2023 11:29:23 +0000 (11:29 +0000)
The initial ret is not used anywhere, drop the unneeded assignment.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20231016161005.1471768-5-andriy.shevchenko@linux.intel.com
Signed-off-by: Lee Jones <lee@kernel.org>
drivers/leds/leds-gpio.c

index fd3f90f95fa244dc9091059f418b733a6b59419e..d6e8298ffb3e6cbda2187f2f74c35217fdc15c02 100644 (file)
@@ -255,7 +255,7 @@ static int gpio_led_probe(struct platform_device *pdev)
        struct device *dev = &pdev->dev;
        struct gpio_led_platform_data *pdata = dev_get_platdata(dev);
        struct gpio_leds_priv *priv;
-       int i, ret = 0;
+       int i, ret;
 
        if (pdata && pdata->num_leds) {
                priv = devm_kzalloc(dev, struct_size(priv, leds, pdata->num_leds), GFP_KERNEL);