diff options
| author | Fabian Frederick <[email protected]> | 2014-05-09 18:32:25 +0000 |
|---|---|---|
| committer | John Stultz <[email protected]> | 2014-05-12 17:09:25 +0000 |
| commit | cdafb93feb3d0ae3131f631a10f70954c96cbef8 (patch) | |
| tree | 2af5609063eaeb9201f7c3bab2abc07ccf090e8b | |
| parent | sched_clock: Remove deprecated setup_sched_clock() API (diff) | |
| download | kernel-cdafb93feb3d0ae3131f631a10f70954c96cbef8.tar.gz kernel-cdafb93feb3d0ae3131f631a10f70954c96cbef8.zip | |
ntp: Convert simple_strtol to kstrtol
Replace obsolete function simple_strtol w/ kstrtol
Inspired-By: Andrew Morton <[email protected]>
Cc: John Stultz <[email protected]>
Cc: Andrew Morton <[email protected]>
Signed-off-by: Fabian Frederick <[email protected]>
[jstultz: Tweak commit message]
Signed-off-by: John Stultz <[email protected]>
| -rw-r--r-- | kernel/time/ntp.c | 5 |
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; |
