pinctrl: bcm2835: Fix a few error paths
authorFlorian Fainelli <f.fainelli@gmail.com>
Thu, 27 Jan 2022 21:50:31 +0000 (13:50 -0800)
committerLinus Walleij <linus.walleij@linaro.org>
Sun, 30 Jan 2022 01:33:39 +0000 (02:33 +0100)
commit5297c693d8c8e08fa742e3112cf70723f7a04da2
treec8d9ada6b2d174c12733c207502a805172417e14
parent474932a3b215de3dffd828d5ef3296275b80ea01
pinctrl: bcm2835: Fix a few error paths

After commit 266423e60ea1 ("pinctrl: bcm2835: Change init order for gpio
hogs") a few error paths would not unwind properly the registration of
gpio ranges. Correct that by assigning a single error label and goto it
whenever we encounter a fatal error.

Fixes: 266423e60ea1 ("pinctrl: bcm2835: Change init order for gpio hogs")
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Link: https://lore.kernel.org/r/20220127215033.267227-1-f.fainelli@gmail.com
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/pinctrl/bcm/pinctrl-bcm2835.c