diff options
Diffstat (limited to 'drivers/pinctrl/samsung/pinctrl-samsung.c')
-rw-r--r-- | drivers/pinctrl/samsung/pinctrl-samsung.c | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/drivers/pinctrl/samsung/pinctrl-samsung.c b/drivers/pinctrl/samsung/pinctrl-samsung.c index b07406da333c..83faddf456e0 100644 --- a/drivers/pinctrl/samsung/pinctrl-samsung.c +++ b/drivers/pinctrl/samsung/pinctrl-samsung.c | |||
@@ -945,9 +945,7 @@ static int samsung_gpiolib_register(struct platform_device *pdev, | |||
945 | 945 | ||
946 | fail: | 946 | fail: |
947 | for (--i, --bank; i >= 0; --i, --bank) | 947 | for (--i, --bank; i >= 0; --i, --bank) |
948 | if (gpiochip_remove(&bank->gpio_chip)) | 948 | gpiochip_remove(&bank->gpio_chip); |
949 | dev_err(&pdev->dev, "gpio chip %s remove failed\n", | ||
950 | bank->gpio_chip.label); | ||
951 | return ret; | 949 | return ret; |
952 | } | 950 | } |
953 | 951 | ||
@@ -957,16 +955,11 @@ static int samsung_gpiolib_unregister(struct platform_device *pdev, | |||
957 | { | 955 | { |
958 | struct samsung_pin_ctrl *ctrl = drvdata->ctrl; | 956 | struct samsung_pin_ctrl *ctrl = drvdata->ctrl; |
959 | struct samsung_pin_bank *bank = ctrl->pin_banks; | 957 | struct samsung_pin_bank *bank = ctrl->pin_banks; |
960 | int ret = 0; | ||
961 | int i; | 958 | int i; |
962 | 959 | ||
963 | for (i = 0; !ret && i < ctrl->nr_banks; ++i, ++bank) | 960 | for (i = 0; i < ctrl->nr_banks; ++i, ++bank) |
964 | ret = gpiochip_remove(&bank->gpio_chip); | 961 | gpiochip_remove(&bank->gpio_chip); |
965 | 962 | return 0; | |
966 | if (ret) | ||
967 | dev_err(&pdev->dev, "gpio chip remove failed\n"); | ||
968 | |||
969 | return ret; | ||
970 | } | 963 | } |
971 | 964 | ||
972 | static const struct of_device_id samsung_pinctrl_dt_match[]; | 965 | static const struct of_device_id samsung_pinctrl_dt_match[]; |