diff options
author | Joey Gouly <joey.gouly@arm.com> | 2021-11-21 19:56:38 +0300 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2021-11-27 02:55:14 +0300 |
commit | a8888e64eec8f8e50917f9e616f45ff2ad01be66 (patch) | |
tree | b7d425dc3834f1962c48093ff1e87ba4b6682da3 /drivers/pinctrl/pinctrl-apple-gpio.c | |
parent | 7d2649172908c83c820a957e97d0baf9901b9c95 (diff) | |
download | linux-a8888e64eec8f8e50917f9e616f45ff2ad01be66.tar.xz |
pinctrl: apple: give error label a specific name
Signed-off-by: Joey Gouly <joey.gouly@arm.com>
Suggested-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Link: https://lore.kernel.org/r/20211121165642.27883-8-joey.gouly@arm.com
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl/pinctrl-apple-gpio.c')
-rw-r--r-- | drivers/pinctrl/pinctrl-apple-gpio.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/pinctrl/pinctrl-apple-gpio.c b/drivers/pinctrl/pinctrl-apple-gpio.c index fba2d4ec383c..fb34cbe189ce 100644 --- a/drivers/pinctrl/pinctrl-apple-gpio.c +++ b/drivers/pinctrl/pinctrl-apple-gpio.c @@ -392,13 +392,13 @@ static int apple_gpio_register(struct apple_gpio_pinctrl *pctl) GFP_KERNEL); if (!girq->parents || !irq_data) { ret = -ENOMEM; - goto out; + goto out_free_irq_data; } for (i = 0; i < girq->num_parents; i++) { ret = platform_get_irq(to_platform_device(pctl->dev), i); if (ret < 0) - goto out; + goto out_free_irq_data; girq->parents[i] = ret; pctl->irqgrps[i] = i; @@ -412,7 +412,8 @@ static int apple_gpio_register(struct apple_gpio_pinctrl *pctl) } ret = devm_gpiochip_add_data(pctl->dev, &pctl->gpio_chip, pctl); -out: + +out_free_irq_data: kfree(girq->parents); kfree(irq_data); |