[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20190513073429.12023-1-lee.jones@linaro.org>
Date: Mon, 13 May 2019 08:34:28 +0100
From: Lee Jones <lee.jones@...aro.org>
To: linus.walleij@...aro.org
Cc: linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
amelie.delaunay@...com, Lee Jones <lee.jones@...aro.org>
Subject: [PATCH 1/2] pinctrl: stmfx: Fix 'warn: unsigned <VAR> is never less than zero'
smatch warnings:
drivers/pinctrl/pinctrl-stmfx.c:225 stmfx_pinconf_get() warn: unsigned 'dir' is never less than zero.
drivers/pinctrl/pinctrl-stmfx.c:228 stmfx_pinconf_get() warn: unsigned 'type' is never less than zero.
drivers/pinctrl/pinctrl-stmfx.c:231 stmfx_pinconf_get() warn: unsigned 'pupd' is never less than zero.
Reported-by: kbuild test robot <lkp@...el.com>
Signed-off-by: Lee Jones <lee.jones@...aro.org>
---
drivers/pinctrl/pinctrl-stmfx.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/pinctrl/pinctrl-stmfx.c b/drivers/pinctrl/pinctrl-stmfx.c
index bcd81269445e..074c8fa3e75c 100644
--- a/drivers/pinctrl/pinctrl-stmfx.c
+++ b/drivers/pinctrl/pinctrl-stmfx.c
@@ -213,9 +213,8 @@ static int stmfx_pinconf_get(struct pinctrl_dev *pctldev,
struct stmfx_pinctrl *pctl = pinctrl_dev_get_drvdata(pctldev);
u32 param = pinconf_to_config_param(*config);
struct pinctrl_gpio_range *range;
- u32 dir, type, pupd;
u32 arg = 0;
- int ret;
+ int ret, dir, type, pupd;
range = pinctrl_find_gpio_range_from_pin_nolock(pctldev, pin);
if (!range)
--
2.17.1
Powered by blists - more mailing lists