1
.\" This is free documentation; you can redistribute it and/or
2
.\" modify it under the terms of the GNU General Public License as
3
.\" published by the Free Software Foundation; either version 2 of
4
.\" the License, or (at your option) any later version.
6
.\" The GNU General Public License's references to "object code"
7
.\" and "executables" are to be interpreted as the output of any
8
.\" document formatting or typesetting system, including
9
.\" intermediate and printed output.
11
.\" This manual is distributed in the hope that it will be useful,
12
.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
13
.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
.\" GNU General Public License for more details.
16
.\" You should have received a copy of the GNU General Public
17
.\" License along with this manual; if not, write to the Free
18
.\" Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111,
21
.\" 2002-02-16, joey: Converted from glibc.info
23
.TH ADJTIME 2 2002-02-16 "Linux 2.0" "Linux Programmer's Manual"
25
adjtime \- smoothly tune kernel clock
27
.B #include <sys/time.h>
29
.BI "int adjtime(const struct timeval *" delta ", struct timeval *" olddelta );
31
This function speeds up or slows down the system clock in order to
32
make a gradual adjustment. This ensures that the calendar time
33
reported by the system clock is always monotonically increasing, which
34
might not happen if you simply set the clock.
38
argument specifies a relative adjustment to be made to the clock time.
39
If negative, the system clock is slowed down fora while until it has
40
lost this much elapsed time. If positive, the system clock is speeded
45
argument is not a null pointer, the
47
function returns information about any previous time adjustment that
48
has not yet completed.
50
This function is typically used to synchronize the clocks of computers
51
in a local network. You must be a privileged user to use it.
55
function returns 0 on success and -1 on failure and sets the external
62
The calling process does not have enough privileges to access the clock.
64
With a Linux kernel, you can use the
66
function to permanently change the system clock speed.
68
This function is derived from 4.3 BSD and SVr4.