Import the NetBSD rdate command and remove the Minix rdate command.
The default behaviour for both is the same. The NetBSD version adds
options to just display the time, adjust the time using adjtime(),
and set the time without printing the time.
Porting Notes:
- Compiles cleanly out of the box without any warnings
- Path changes from /usr/bin/rdate to /usr/sbin/rdate
- checked pkgsrc for any usages of rdate (none found)
- checked src for any usages of rdate (none found)
Testing:
- all command line options work (tested with time.nist.gov server)
- Native and cross build OK
Change-Id: I613449763891a896527f337999c006a970c3924c
. fixed overflow in ticks compare function, causing
occasionally esp. the kernel to be mis-ordered by cpu
time
. fixed some const string related warnings
. fixed some variable name shadowing warnings
Change-Id: I02c177b1579bce164372f9b03f6b472537cc9e3e
. inet: silence message about exceptions not being implemented
for select(UDP)
This message generates a lot of noise with openntpd. Hide it unless DEBUG is
turned on.
Change-Id: I1527a9ca2583601d6087456062b4f675c80dd711
This also adds the sys_settime() kernel call which allows for the adjusting
of the clock named realtime in the kernel. The existing sys_stime()
function is still needed for a separate job (setting the boottime). The
boottime is set in the readclock driver. The sys_settime() interface is
meant to be flexible and will support both clock_settime() and adjtime()
when adjtime() is implemented later.
settimeofday() was adjusted to use the clock_settime() interface.
One side note discovered during testing: uptime(1) (part of the last(1)),
uses wtmp to determine boottime (not Minix's times(2)). This leads `uptime`
to report odd results when you set the time to a time prior to boottime.
This isn't a new bug introduced by my changes. It's been there for a while.
In order to make it more clear that ticks should be used for timers
and realtime should be used for timestamps / displaying the date/time,
getuptime() was renamed to getticks() and getuptime2() was renamed to
getuptime().
Servers, drivers, libraries, tests, etc that use getuptime()/getuptime2()
have been updated. In instances where a realtime was calculated, the
calculation was changed to use realtime.
System calls clock_getres() and clock_gettime() were added to PM/libc.
Old realtime was used for both timers (where an accurate count of
all ticks is needed) and the system time. In order to implement
adjtime(2), these duties must be separated as changing the time
of day by a small amount shouldn't affect timers in any way nor
should it change the boot time.
Following the naming of the clocks used by clock_gettime(2). The
clock named 'realtime' will represent the best guess at the
current wall clock time, and the clock named 'monotonic' will
represent the absolute time the system has been running.
Use monotonic for timers in kernel and in drivers. Use realtime
for determining time of day, dates, etc.
This commit simply renames realtime to monotonic and adds a new
tick counter named realtime. There are no functional changes in
this commit. It just lays the foundation for future work.
. split user-editable and system-owned files in etc/Makefile
. mtab is a symlink, not a file now; remove it
. force-install of certain system-controlled /etc files from
top Makefile
. rename /etc/make.conf to /etc/mk.conf; and don't set $ARCH;
reduce difference in bsd.own.mk
Change-Id: I9f4bbb8d37ba80cba7dcfcf1a9a89e934910f579
pkgin now depends on pkg_install. If pkg_install appears after pkgin
in PREINSTALLED_PACKAGES, there will be an error because pkg_install
was installed as a dependency for pkgin.
. data structure that automatically keeps a set
of pages in reserve, to replace sparepages and
possibly re-used in the future for similar situations,
e.g. if in-filesystem-cache block eviction is
implemented and FS asks for a new block
Change-Id: I149d46c14b9c8e75df16cb94e08907f008c339a6
Install /home/ast and /home/bin as part of the system build procedure,
as the setup script is not ran on the arm image.
/home/bin is needed for successful completion of our test suite.
This patch does not change the setup script, as it is not bothered by
those files/directiories being already there, and may be useful during
reinstallation on intel systems.
Change-Id: I358c881df09223c343442673aa0822937f9ea33c
When you provided a string with junk after the terminating nul to a
UNIX domain socket and used bind(2), the canonical path function would
not properly terminate the new string. This caused VFS to return
ENAMETOOLONG on an otherwise valid path name.
Test case is added to test56.
Change-Id: I883b6be23d9e4ea13c3cee28cbb3726343df037f
* Use the same output directory as was previously the standard.
* Add copying of uEnv and cmdline to the obj directory to allow booting from tftp.
* No longer start qemu at the end of the process.
* Use sudo if the script was called as non root user.
Change-Id: I53143b1ce6633e764d173c3eb883c2efa3e6a5b7