[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220927205916.511556-1-horatiu.vultur@microchip.com>
Date: Tue, 27 Sep 2022 22:59:16 +0200
From: Horatiu Vultur <horatiu.vultur@...rochip.com>
To: <linux-kernel@...r.kernel.org>
CC: <srinivas.kandagatla@...aro.org>, <gregkh@...uxfoundation.org>,
"Horatiu Vultur" <horatiu.vultur@...rochip.com>,
kernel test robot <lkp@...el.com>,
"Dan Carpenter" <dan.carpenter@...cle.com>
Subject: [PATCH] nvmem: lan9662-otp: Change return type of lan9662_otp_wait_flag_clear()
The blamed commit introduced the following smatch warning in the
function lan9662_otp_wait_flag_clear:
drivers/nvmem/lan9662-otpc.c:43 lan9662_otp_wait_flag_clear() warn: signedness bug returning '(-110)'
Fix this by changing the return type of the function
lan9662_otp_wait_flag_clear() to be int instead of bool.
Fixes: 9e8f208ad5229d ("nvmem: lan9662-otp: add support")
Reported-by: kernel test robot <lkp@...el.com>
Reported-by: Dan Carpenter <dan.carpenter@...cle.com>
Signed-off-by: Horatiu Vultur <horatiu.vultur@...rochip.com>
---
drivers/nvmem/lan9662-otpc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/nvmem/lan9662-otpc.c b/drivers/nvmem/lan9662-otpc.c
index f6732fd216d80..f4348c97f6e59 100644
--- a/drivers/nvmem/lan9662-otpc.c
+++ b/drivers/nvmem/lan9662-otpc.c
@@ -36,7 +36,7 @@ struct lan9662_otp {
void __iomem *base;
};
-static bool lan9662_otp_wait_flag_clear(void __iomem *reg, u32 flag)
+static int lan9662_otp_wait_flag_clear(void __iomem *reg, u32 flag)
{
u32 val;
--
2.33.0
Powered by blists - more mailing lists