ksettimer Kernel Service

Purpose

Sets the systemwide time-of-day timer.

Syntax

#include <sys/types.h>
#include <sys/errno.h>
#include <sys/time.h>
int ksettimer (nct) 
struct timestruc_t *nct;

Parameter

Item Description
nct Points to a timestruc_t structure, which contains the new current time to be set. The nanoseconds member of this structure is valid only if greater than or equal to 0, and less than the number of nanoseconds in a second.

Description

The ksettimer kernel service provides a kernel extension with the capability to set the systemwide time-of-day timer. Kernel extensions typically use this kernel service to support network coordinated time, which is the periodic synchronization of all system clocks to a common time by a time server or set of time servers on a network. The newly set "current" time must represent the amount of time since 00:00:00 GMT, January 1, 1970.

Execution Environment

The ksettimer kernel service can be called from the process environment only.

Return Values

Item Description
0 Indicates success.
EINVAL Indicates that the new current time specified by the nct parameter is outside the range of the systemwide timer.
EIO Indicates that an error occurred while this kernel service was accessing the timer device.