projects
/
fio.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'esx-timerfd-bypass' of https://github.com/brianredbeard/fio
[fio.git]
/
os
/
os-dragonfly.h
diff --git
a/os/os-dragonfly.h
b/os/os-dragonfly.h
index 713046f53543442a89d21c55ace2cbcd05839d4b..44bfcd5d064001722567d8c2011665b612a13d4b 100644
(file)
--- a/
os/os-dragonfly.h
+++ b/
os/os-dragonfly.h
@@
-10,15
+10,21
@@
#include <sys/sysctl.h>
#include <sys/statvfs.h>
#include <sys/diskslice.h>
#include <sys/sysctl.h>
#include <sys/statvfs.h>
#include <sys/diskslice.h>
-#include <sys/ioctl_compat.h>
#include <sys/usched.h>
#include <sys/resource.h>
#include <sys/usched.h>
#include <sys/resource.h>
+/* API changed during "5.3 development" */
+#if __DragonFly_version < 500302
+#include <sys/ioctl_compat.h>
+#define DAIOCTRIM IOCTLTRIM
+#else
+#include <bus/cam/scsi/scsi_daio.h>
+#endif
+
#include "../file.h"
#include "../lib/types.h"
#define FIO_HAVE_ODIRECT
#include "../file.h"
#include "../lib/types.h"
#define FIO_HAVE_ODIRECT
-#define FIO_USE_GENERIC_RAND
#define FIO_USE_GENERIC_INIT_RANDOM_STATE
#define FIO_HAVE_FS_STAT
#define FIO_HAVE_TRIM
#define FIO_USE_GENERIC_INIT_RANDOM_STATE
#define FIO_HAVE_FS_STAT
#define FIO_HAVE_TRIM
@@
-41,7
+47,6
@@
/* This is supposed to equal (sizeof(cpumask_t)*8) */
#define FIO_MAX_CPUS SMP_MAXCPU
/* This is supposed to equal (sizeof(cpumask_t)*8) */
#define FIO_MAX_CPUS SMP_MAXCPU
-typedef off_t off64_t;
typedef cpumask_t os_cpu_mask_t;
/*
typedef cpumask_t os_cpu_mask_t;
/*
@@
-196,10
+201,12
@@
static inline unsigned long long os_phys_mem(void)
return mem;
}
return mem;
}
+#ifndef CONFIG_HAVE_GETTID
static inline int gettid(void)
{
return (int) lwp_gettid();
}
static inline int gettid(void)
{
return (int) lwp_gettid();
}
+#endif
static inline unsigned long long get_fs_free_size(const char *path)
{
static inline unsigned long long get_fs_free_size(const char *path)
{
@@
-222,7
+229,7
@@
static inline int os_trim(struct fio_file *f, unsigned long long start,
range[0] = start;
range[1] = len;
range[0] = start;
range[1] = len;
- if (!ioctl(f->fd,
IOCTL
TRIM, range))
+ if (!ioctl(f->fd,
DAIOC
TRIM, range))
return 0;
return errno;
return 0;
return errno;