aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZheng Yongjun <zhengyongjun3@huawei.com>2020-12-10 21:57:46 +0800
committerLinus Walleij <linus.walleij@linaro.org>2020-12-12 01:42:06 +0100
commit3df09cb8c92e2bdfb78c81f678f6990bd780f09a (patch)
tree9c6f400ae1514972b764b9c04e2898049ff403c1
parenta15f859694c2e36bc98e08c9635b27cf2239f4f2 (diff)
pinctrl/spear: simplify the return expression of spear300_pinctrl_probe()pinctrl-v5.11-1
Simplify the return expression. Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Link: https://lore.kernel.org/r/20201210135746.1492-1-zhengyongjun3@huawei.com Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
-rw-r--r--drivers/pinctrl/spear/pinctrl-spear300.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/pinctrl/spear/pinctrl-spear300.c b/drivers/pinctrl/spear/pinctrl-spear300.c
index e39913a18139..d53a04597cbe 100644
--- a/drivers/pinctrl/spear/pinctrl-spear300.c
+++ b/drivers/pinctrl/spear/pinctrl-spear300.c
@@ -654,8 +654,6 @@ static const struct of_device_id spear300_pinctrl_of_match[] = {
static int spear300_pinctrl_probe(struct platform_device *pdev)
{
- int ret;
-
spear3xx_machdata.groups = spear300_pingroups;
spear3xx_machdata.ngroups = ARRAY_SIZE(spear300_pingroups);
spear3xx_machdata.functions = spear300_functions;
@@ -669,11 +667,7 @@ static int spear300_pinctrl_probe(struct platform_device *pdev)
pmx_init_addr(&spear3xx_machdata, PMX_CONFIG_REG);
- ret = spear_pinctrl_probe(pdev, &spear3xx_machdata);
- if (ret)
- return ret;
-
- return 0;
+ return spear_pinctrl_probe(pdev, &spear3xx_machdata);
}
static struct platform_driver spear300_pinctrl_driver = {