esp-open-rtos/libc/xtensa-lx106-elf/include/machine/time.h
Angus Gratton 689cf874b2 Provide our own newlib libc
Newlib 2.2.0 w/ nan ofeatures, xtensa patches, locking
implementation.

Built from https://github.com/projectgus/newlib-xtensa
branch xtensa-2_2_0-lock
commit daa6ae40cdc8099f54c3e68a586fc1b906169c5a

For more details, see:
https://github.com/SuperHouse/esp-open-rtos/wiki/libc-configuration

Closes #1
2015-07-15 15:17:59 +10:00

19 lines
399 B
C

#ifndef _MACHTIME_H_
#define _MACHTIME_H_
#if defined(__rtems__)
#define _CLOCKS_PER_SEC_ sysconf(_SC_CLK_TCK)
#else /* !__rtems__ */
#if defined(__aarch64__) || defined(__arm__) || defined(__thumb__)
#define _CLOCKS_PER_SEC_ 100
#endif
#endif /* !__rtems__ */
#ifdef __SPU__
#include <sys/types.h>
int nanosleep (const struct timespec *, struct timespec *);
#endif
#endif /* _MACHTIME_H_ */