[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1394577653-8615-17-git-send-email-daniel.lezcano@linaro.org>
Date: Tue, 11 Mar 2014 23:40:53 +0100
From: Daniel Lezcano <daniel.lezcano@...aro.org>
To: tglx@...utronix.de, mingo@...nel.org
Cc: linux-kernel@...r.kernel.org, dan.carpenter@...cle.com,
ezequiel.garcia@...e-electrons.com, ivan.khoronzhuk@...com,
linus.walleij@...aro.org, magnus.damm@...il.com,
matthias.bgg@...il.com, soren.brinkmann@...inx.com,
sboyd@...eaurora.org
Subject: [PATCH 17/17] clocksource: exynos_mct: silence a static checker warning
From: Dan Carpenter <dan.carpenter@...cle.com>
My guess is we aren't going to have a 2 digit cpuid here any time soon
but the static checkers don't know that and complain that the snprintf()
could overflow.
Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>
Signed-off-by: Daniel Lezcano <daniel.lezcano@...aro.org>
---
drivers/clocksource/exynos_mct.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/clocksource/exynos_mct.c b/drivers/clocksource/exynos_mct.c
index 48f76bc..c2e390e 100644
--- a/drivers/clocksource/exynos_mct.c
+++ b/drivers/clocksource/exynos_mct.c
@@ -410,7 +410,7 @@ static int exynos4_local_timer_setup(struct clock_event_device *evt)
mevt = container_of(evt, struct mct_clock_event_device, evt);
mevt->base = EXYNOS4_MCT_L_BASE(cpu);
- sprintf(mevt->name, "mct_tick%d", cpu);
+ snprintf(mevt->name, sizeof(mevt->name), "mct_tick%d", cpu);
evt->name = mevt->name;
evt->cpumask = cpumask_of(cpu);
--
1.7.9.5
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists