1 #ifndef _SYS_UIO_H 2 #define _SYS_UIO_H 3 4 #ifdef __cplusplus 5 extern "C" { 6 #endif 7 8 #include <features.h> 9 10 #define __NEED_size_t 11 #define __NEED_ssize_t 12 #define __NEED_struct_iovec 13 14 #if defined(_GNU_SOURCE) || defined(_BSD_SOURCE) 15 #define __NEED_off_t 16 #endif 17 18 #ifdef _GNU_SOURCE 19 #define __NEED_pid_t 20 #endif 21 22 #include <bits/alltypes.h> 23 24 #define UIO_MAXIOV 1024 25 26 ssize_t vfs_readv(int fd, const struct iovec *iov, int iovcnt, off_t *offset); 27 ssize_t vfs_writev(int fd, const struct iovec *iov, int iovcnt, off_t *offset); 28 29 ssize_t readv (int, const struct iovec *, int); 30 ssize_t writev (int, const struct iovec *, int); 31 32 #if defined(_GNU_SOURCE) || defined(_BSD_SOURCE) 33 ssize_t preadv (int, const struct iovec *, int, off_t); 34 ssize_t pwritev (int, const struct iovec *, int, off_t); 35 #if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE) 36 #define preadv64 preadv 37 #define pwritev64 pwritev 38 #endif 39 #endif 40 41 #ifdef _GNU_SOURCE 42 ssize_t process_vm_writev(pid_t, const struct iovec *, unsigned long, const struct iovec *, unsigned long, unsigned long); 43 ssize_t process_vm_readv(pid_t, const struct iovec *, unsigned long, const struct iovec *, unsigned long, unsigned long); 44 #endif 45 46 #ifdef __cplusplus 47 } 48 #endif 49 50 #endif 51