client: use temp buffer for single output flush for json/disk util
[fio.git] / helpers.c
... / ...
CommitLineData
1#include <errno.h>
2
3#include "helpers.h"
4
5#ifndef CONFIG_LINUX_FALLOCATE
6int fallocate(int fd, int mode, off_t offset, off_t len)
7{
8 errno = ENOSYS;
9 return -1;
10}
11#endif
12
13#ifndef CONFIG_POSIX_FALLOCATE
14int posix_fallocate(int fd, off_t offset, off_t len)
15{
16 return 0;
17}
18#endif
19
20#ifndef CONFIG_SYNC_FILE_RANGE
21int sync_file_range(int fd, off64_t offset, off64_t nbytes, unsigned int flags)
22{
23 errno = ENOSYS;
24 return -1;
25}
26#endif
27
28#ifndef CONFIG_POSIX_FADVISE
29int posix_fadvise(int fd, off_t offset, off_t len, int advice)
30{
31 return 0;
32}
33#endif