Xenomai 3.3.2
Loading...
Searching...
No Matches
internal.h
Go to the documentation of this file.
1
21#ifndef __ANALOGY_LIB_INTERNAL__
22#define __ANALOGY_LIB_INTERNAL__
23
24#define MAGIC_BSC_DESC 0x1234abcd
25#define MAGIC_CPLX_DESC 0xabcd1234
26
27#include <rtdm/rtdm.h>
28
29#ifndef DOXYGEN_CPP
30
31static inline int __sys_open(const char *fname)
32{
33 return __RT(open(fname, 0));
34}
35
36static inline int __sys_close(int fd)
37{
38 return __RT(close(fd));
39}
40
41static inline int __sys_ioctl(int fd, int request, void *arg)
42{
43 return __RT(ioctl(fd, request, arg));
44}
45
46static inline ssize_t __sys_read(int fd, void *buf, size_t nbyte)
47{
48 return __RT(read(fd, buf, nbyte));
49}
50
51static inline ssize_t __sys_write(int fd, const void *buf, size_t nbyte)
52{
53 return __RT(write(fd, buf, nbyte));
54}
55
56#endif /* !DOXYGEN_CPP */
57
58#endif /* __ANALOGY_LIB_INTERNAL__ */