Changeset View
Changeset View
Standalone View
Standalone View
lib/libc/sys/clock_gettime.2
Show All 23 Lines | ||||||||||||||
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | |||||||||||||
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT | .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT | |||||||||||||
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | |||||||||||||
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | |||||||||||||
.\" SUCH DAMAGE. | .\" SUCH DAMAGE. | |||||||||||||
.\" | .\" | |||||||||||||
.\" $FreeBSD$ | .\" $FreeBSD$ | |||||||||||||
.\" | .\" | |||||||||||||
.Dd July 8, 2022 | .Dd August 3, 2022 | |||||||||||||
.Dt CLOCK_GETTIME 2 | .Dt CLOCK_GETTIME 2 | |||||||||||||
.Os | .Os | |||||||||||||
.Sh NAME | .Sh NAME | |||||||||||||
.Nm clock_gettime , | .Nm clock_gettime , | |||||||||||||
.Nm clock_settime , | .Nm clock_settime , | |||||||||||||
.Nm clock_getres | .Nm clock_getres | |||||||||||||
.Nd get/set/calibrate date and time | .Nd get/set/calibrate date and time | |||||||||||||
.Sh LIBRARY | .Sh LIBRARY | |||||||||||||
▲ Show 20 Lines • Show All 76 Lines • ▼ Show 20 Lines | ||||||||||||||
execution time. | execution time. | |||||||||||||
The clock IDs | The clock IDs | |||||||||||||
.Fa CLOCK_REALTIME_COARSE | .Fa CLOCK_REALTIME_COARSE | |||||||||||||
and | and | |||||||||||||
.Fa CLOCK_MONOTONIC_COARSE | .Fa CLOCK_MONOTONIC_COARSE | |||||||||||||
are aliases of corresponding IDs with _FAST suffix for compatibility with other | are aliases of corresponding IDs with _FAST suffix for compatibility with other | |||||||||||||
systems. | systems. | |||||||||||||
Finally, | Finally, | |||||||||||||
.Dv CLOCK_BOOTTIME | .Dv CLOCK_BOOTTIME | |||||||||||||
is an alias for | is an alias for | |||||||||||||
.Dv CLOCK_UPTIME | .Dv CLOCK_UPTIME | |||||||||||||
pauamma_gundo.com: While here, make these .Fa to match the other aliases above, eg CLOCK_MONOTONIC_COARSE. | ||||||||||||||
for compatibility with other systems. | for compatibility with other systems (which is unrelated to the | |||||||||||||
.Fa kern.bootitme | ||||||||||||||
.Xr sysctl 8 ) . | ||||||||||||||
pauamma_gundo.comUnsubmitted Not Done Inline Actions
pauamma_gundo.com: | ||||||||||||||
.Pp | .Pp | |||||||||||||
The structure pointed to by | The structure pointed to by | |||||||||||||
.Fa tp | .Fa tp | |||||||||||||
is defined in | is defined in | |||||||||||||
.In sys/timespec.h | .In sys/timespec.h | |||||||||||||
as: | as: | |||||||||||||
.Bd -literal | .Bd -literal | |||||||||||||
struct timespec { | struct timespec { | |||||||||||||
▲ Show 20 Lines • Show All 73 Lines • Show Last 20 Lines |
While here, make these .Fa to match the other aliases above, eg CLOCK_MONOTONIC_COARSE.