Line data Source code
1 0 : /*
2 : * Copyright (c) 2018 Linaro Limited
3 : *
4 : * SPDX-License-Identifier: Apache-2.0
5 : */
6 :
7 : #ifndef ZEPHYR_POSIX_FCNTL_H_
8 : #define ZEPHYR_POSIX_FCNTL_H_
9 :
10 : #include <zephyr/sys/fdtable.h>
11 :
12 0 : #define O_APPEND ZVFS_O_APPEND
13 0 : #define O_CREAT ZVFS_O_CREAT
14 0 : #define O_EXCL ZVFS_O_EXCL
15 0 : #define O_NONBLOCK ZVFS_O_NONBLOCK
16 0 : #define O_TRUNC ZVFS_O_TRUNC
17 :
18 0 : #define O_ACCMODE (ZVFS_O_RDONLY | ZVFS_O_RDWR | ZVFS_O_WRONLY)
19 :
20 0 : #define O_RDONLY ZVFS_O_RDONLY
21 0 : #define O_RDWR ZVFS_O_RDWR
22 0 : #define O_WRONLY ZVFS_O_WRONLY
23 :
24 0 : #define F_DUPFD ZVFS_F_DUPFD
25 0 : #define F_GETFL ZVFS_F_GETFL
26 0 : #define F_SETFL ZVFS_F_SETFL
27 :
28 : #ifdef __cplusplus
29 : extern "C" {
30 : #endif
31 :
32 0 : int open(const char *name, int flags, ...);
33 0 : int fcntl(int fildes, int cmd, ...);
34 :
35 : #ifdef __cplusplus
36 : }
37 : #endif
38 :
39 : #endif /* ZEPHYR_POSIX_FCNTL_H_ */
|