* [PATCH 1/3] pinctrl: pinconf: fix comparison of different types
@ 2013-08-06 9:10 Jingoo Han
2013-08-07 19:34 ` Linus Walleij
0 siblings, 1 reply; 2+ messages in thread
From: Jingoo Han @ 2013-08-06 9:10 UTC (permalink / raw)
To: Linus Walleij; +Cc: linux-kernel, Jingoo Han
Fix the following sparse warning:
drivers/pinctrl/pinconf.c:521:20: error: incompatible types in comparison expression (different type sizes)
Signed-off-by: Jingoo Han <jg1.han@samsung.com>
---
drivers/pinctrl/pinconf.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/pinctrl/pinconf.c b/drivers/pinctrl/pinconf.c
index e875f21..1516fb0 100644
--- a/drivers/pinctrl/pinconf.c
+++ b/drivers/pinctrl/pinconf.c
@@ -518,7 +518,7 @@ static int pinconf_dbg_config_write(struct file *file,
int i;
/* Get userspace string and assure termination */
- buf_size = min(count, (sizeof(buf)-1));
+ buf_size = min(count, (size_t)(sizeof(buf)-1));
if (copy_from_user(buf, user_buf, buf_size))
return -EFAULT;
buf[buf_size] = 0;
--
1.7.10.4
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-08-07 19:34 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-08-06 9:10 [PATCH 1/3] pinctrl: pinconf: fix comparison of different types Jingoo Han
2013-08-07 19:34 ` Linus Walleij
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®