diff options
author | James Morris <jmorris@namei.org> | 2011-04-19 07:32:41 -0400 |
---|---|---|
committer | James Morris <jmorris@namei.org> | 2011-04-19 07:32:41 -0400 |
commit | d4ab4e6a23f805abb8fc3cc34525eec3788aeca1 (patch) | |
tree | eefd82c155bc27469a85667d759cd90facf4a6e3 /kernel/time/ntp.c | |
parent | c0fa797ae6cd02ff87c0bfe0d509368a3b45640e (diff) | |
parent | 96fd2d57b8252e16dfacf8941f7a74a6119197f5 (diff) |
Merge branch 'master'; commit 'v2.6.39-rc3' into next
Diffstat (limited to 'kernel/time/ntp.c')
-rw-r--r-- | kernel/time/ntp.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/kernel/time/ntp.c b/kernel/time/ntp.c index 5f1bb8e2008f..f6117a4c7cb8 100644 --- a/kernel/time/ntp.c +++ b/kernel/time/ntp.c | |||
@@ -652,6 +652,8 @@ int do_adjtimex(struct timex *txc) | |||
652 | struct timespec delta; | 652 | struct timespec delta; |
653 | delta.tv_sec = txc->time.tv_sec; | 653 | delta.tv_sec = txc->time.tv_sec; |
654 | delta.tv_nsec = txc->time.tv_usec; | 654 | delta.tv_nsec = txc->time.tv_usec; |
655 | if (!capable(CAP_SYS_TIME)) | ||
656 | return -EPERM; | ||
655 | if (!(txc->modes & ADJ_NANO)) | 657 | if (!(txc->modes & ADJ_NANO)) |
656 | delta.tv_nsec *= 1000; | 658 | delta.tv_nsec *= 1000; |
657 | result = timekeeping_inject_offset(&delta); | 659 | result = timekeeping_inject_offset(&delta); |