Zephyr API Documentation  3.6.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
time.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2019 Linaro Limited
3 *
4 * SPDX-License-Identifier: Apache-2.0
5 */
6
7#ifndef ZEPHYR_INCLUDE_POSIX_SYS_TIME_H_
8#define ZEPHYR_INCLUDE_POSIX_SYS_TIME_H_
9
10#ifdef CONFIG_NEWLIB_LIBC
11/* Kludge to support outdated newlib version as used in SDK 0.10 for Xtensa */
12#include <newlib.h>
13
14#ifdef __NEWLIB__
15#include <sys/_timeval.h>
16#else
17#include <sys/types.h>
18struct timeval {
21};
22#endif
23
24#else
25#include <sys/_timeval.h>
26#endif /* CONFIG_NEWLIB_LIBC */
27
28#ifdef __cplusplus
29extern "C" {
30#endif
31
32int gettimeofday(struct timeval *tv, void *tz);
33
34#ifdef __cplusplus
35}
36#endif
37
38#endif /* ZEPHYR_INCLUDE_POSIX_SYS_TIME_H_ */
_TIME_T_ time_t
Definition: _timespec.h:14
_SUSECONDS_T_ suseconds_t
Definition: _timespec.h:19
int gettimeofday(struct timeval *tv, void *tz)
Definition: _timeval.h:22
suseconds_t tv_usec
Definition: _timeval.h:24
time_t tv_sec
Definition: _timeval.h:23