summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorFabian Frederick <fabf@skynet.be>2014-05-09 22:32:25 +0400
committerJohn Stultz <john.stultz@linaro.org>2014-05-12 21:09:25 +0400
commitcdafb93feb3d0ae3131f631a10f70954c96cbef8 (patch)
tree2af5609063eaeb9201f7c3bab2abc07ccf090e8b /kernel
parentc04ae71c9c264312a6f57d2665a79f7bbccf8758 (diff)
downloadlinux-cdafb93feb3d0ae3131f631a10f70954c96cbef8.tar.xz
ntp: Convert simple_strtol to kstrtol
Replace obsolete function simple_strtol w/ kstrtol Inspired-By: Andrew Morton <akpm@linux-foundation.org> Cc: John Stultz <john.stultz@linaro.org> Cc: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Fabian Frederick <fabf@skynet.be> [jstultz: Tweak commit message] Signed-off-by: John Stultz <john.stultz@linaro.org>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/time/ntp.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/kernel/time/ntp.c b/kernel/time/ntp.c
index 419a52cecd20..82b7c9edba7e 100644
--- a/kernel/time/ntp.c
+++ b/kernel/time/ntp.c
@@ -923,7 +923,10 @@ void __hardpps(const struct timespec *phase_ts, const struct timespec *raw_ts)
static int __init ntp_tick_adj_setup(char *str)
{
- ntp_tick_adj = simple_strtol(str, NULL, 0);
+ int rc = kstrtol(str, 0, (long *)&ntp_tick_adj);
+
+ if (rc)
+ return rc;
ntp_tick_adj <<= NTP_SCALE_SHIFT;
return 1;