libmetal
Loading...
Searching...
No Matches
sleep.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2018, Linaro Limited. and Contributors. All rights reserved.
3 *
4 * SPDX-License-Identifier: BSD-3-Clause
5 */
6
7/*
8 * @file linux/sleep.h
9 * @brief linux sleep primitives for libmetal.
10 */
11
12#ifndef __METAL_SLEEP__H__
13#error "Include metal/sleep.h instead of metal/linux/sleep.h"
14#endif
15
16#ifndef __METAL_LINUX_SLEEP__H__
17#define __METAL_LINUX_SLEEP__H__
18
19#include <unistd.h>
20
21#ifdef __cplusplus
22extern "C" {
23#endif
24
25static inline int __metal_sleep_usec(unsigned int usec)
26{
27 return usleep(usec);
28}
29
32#ifdef __cplusplus
33}
34#endif
35
36#endif /* __METAL_LINUX_SLEEP__H__ */
static int __metal_sleep_usec(unsigned int usec)
Definition: sleep.h:26