Commit graph

10 commits

Author SHA1 Message Date
Tom Gundersen
910a090039 hwclock: don't warp the systemtime if the RTC is in UTC
A sideeffect of 839be2ba6b is that we now
warp the systemtime according to the timezone, on the first call of
--systz. This is not always the correct thing to do, and causes a
regression for us in Arch Linux.

The behavior is correct if the RTC, and hence the systemtime, is
in localtime. However, if the systemtime is already in UTC we don't
want to touch it when we set the kernel timezone (which we still need to
do as some filesystems use this information).

An almost identical issue was also fixed in systemd commit
72edcff5db936e54cfc322d9392ec46e2428fd9b.

Signed-off-by: Tom Gundersen <teg@jklm.no>
2012-09-21 12:07:32 +02:00
Ondrej Oprala
83765871ef hwclock: add a new --compare option
The new option imitates adjtimex -c functionality and outputs
the drift in 10 second intervals.

[kzak@redhat.com: - coding style
                  - print hw and system time columns too]

Signed-off-by: Karel Zak <kzak@redhat.com>
2012-09-10 16:00:27 +02:00
Karel Zak
dade002ab0 hwclock: use err_exclusive_options()
Signed-off-by: Karel Zak <kzak@redhat.com>
2012-07-26 09:25:48 +02:00
Sami Kerola
289dcc9023 translation: unify file open error messages
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2012-07-16 18:18:22 +02:00
Karel Zak
839be2ba6b hwclock: don't set time for --systz
Not sure why, but the current --systz uses non-NULL timeval for
settimeofday(). It means that build-in kernel warp clock mechanism is
not used and the system time is always modified.

The built-in kernel implementation allows to move the clock by
timezone only for very first settimeofday() call.

Signed-off-by: Karel Zak <kzak@redhat.com>
2012-07-04 13:43:51 +02:00
Karel Zak
c7f753901f build-sys: move hwclock to sys-utils/
Signed-off-by: Karel Zak <kzak@redhat.com>
2012-06-26 20:48:23 +02:00
Karel Zak
7eda085c41 Imported from util-linux-2.9v tarball. 2006-12-07 00:25:39 +01:00
Karel Zak
5c36a0eb7c Imported from util-linux-2.9i tarball. 2006-12-07 00:25:37 +01:00
Karel Zak
2b6fc908bc Imported from util-linux-2.8 tarball. 2006-12-07 00:25:35 +01:00
Karel Zak
fd6b7a7ffc Imported from util-linux-2.7.1 tarball. 2006-12-07 00:25:34 +01:00