* [patch] clockevents: signedness bug checking sysfs_get_uname()
@ 2013-06-21 6:20 Dan Carpenter
0 siblings, 0 replies; only message in thread
From: Dan Carpenter @ 2013-06-21 6:20 UTC (permalink / raw)
To: Thomas Gleixner; +Cc: linux-kernel, kernel-janitors
We check "if (ret < 0) " later so it has to be signed.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
diff --git a/kernel/time/clockevents.c b/kernel/time/clockevents.c
index 38959c8..30554b9 100644
--- a/kernel/time/clockevents.c
+++ b/kernel/time/clockevents.c
@@ -584,7 +584,7 @@ static ssize_t sysfs_unbind_tick_dev(struct device *dev,
const char *buf, size_t count)
{
char name[CS_NAME_LEN];
- size_t ret = sysfs_get_uname(buf, name, count);
+ ssize_t ret = sysfs_get_uname(buf, name, count);
struct clock_event_device *ce;
if (ret < 0)
diff --git a/kernel/time/clocksource.c b/kernel/time/clocksource.c
index e713ef7..228ace1 100644
--- a/kernel/time/clocksource.c
+++ b/kernel/time/clocksource.c
@@ -897,7 +897,7 @@ static ssize_t sysfs_override_clocksource(struct device *dev,
struct device_attribute *attr,
const char *buf, size_t count)
{
- size_t ret;
+ ssize_t ret;
mutex_lock(&clocksource_mutex);
@@ -925,7 +925,7 @@ static ssize_t sysfs_unbind_clocksource(struct device *dev,
{
struct clocksource *cs;
char name[CS_NAME_LEN];
- size_t ret;
+ ssize_t ret;
ret = sysfs_get_uname(buf, name, count);
if (ret < 0)
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2013-06-21 6:20 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-06-21 6:20 [patch] clockevents: signedness bug checking sysfs_get_uname() Dan Carpenter
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).