projects
/
fio.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
doc: add cpus_allowed reference to log_compression_cpus
[fio.git]
/
os
/
os-dragonfly.h
diff --git
a/os/os-dragonfly.h
b/os/os-dragonfly.h
index 8d15833562785ba4db31f1d31bd0e45c30587550..713046f53543442a89d21c55ace2cbcd05839d4b 100644
(file)
--- a/
os/os-dragonfly.h
+++ b/
os/os-dragonfly.h
@@
-15,6
+15,7
@@
#include <sys/resource.h>
#include "../file.h"
#include <sys/resource.h>
#include "../file.h"
+#include "../lib/types.h"
#define FIO_HAVE_ODIRECT
#define FIO_USE_GENERIC_RAND
#define FIO_HAVE_ODIRECT
#define FIO_USE_GENERIC_RAND
@@
-107,12
+108,9
@@
static inline void fio_cpu_set(os_cpu_mask_t *mask, int cpu)
CPUMASK_ORBIT(*mask, cpu);
}
CPUMASK_ORBIT(*mask, cpu);
}
-static inline
int
fio_cpu_isset(os_cpu_mask_t *mask, int cpu)
+static inline
bool
fio_cpu_isset(os_cpu_mask_t *mask, int cpu)
{
{
- if (CPUMASK_TESTBIT(*mask, cpu))
- return 1;
-
- return 0;
+ return CPUMASK_TESTBIT(*mask, cpu) != 0;
}
static inline int fio_setaffinity(int pid, os_cpu_mask_t mask)
}
static inline int fio_setaffinity(int pid, os_cpu_mask_t mask)
@@
-216,7
+214,7
@@
static inline unsigned long long get_fs_free_size(const char *path)
return ret;
}
return ret;
}
-static inline int os_trim(
int fd
, unsigned long long start,
+static inline int os_trim(
struct fio_file *f
, unsigned long long start,
unsigned long long len)
{
off_t range[2];
unsigned long long len)
{
off_t range[2];
@@
-224,7
+222,7
@@
static inline int os_trim(int fd, unsigned long long start,
range[0] = start;
range[1] = len;
range[0] = start;
range[1] = len;
- if (!ioctl(fd, IOCTLTRIM, range))
+ if (!ioctl(f
->f
d, IOCTLTRIM, range))
return 0;
return errno;
return 0;
return errno;