projects
/
fio.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
parse: fix min/max val checking for FIO_OPT_INT
[fio.git]
/
engines
/
pmemblk.c
diff --git
a/engines/pmemblk.c
b/engines/pmemblk.c
index e8476f99ab0782557387a79226dbb3edee4c36a8..45f6fb6501a216b78dbfdae34f7ef3807aa77669 100644
(file)
--- a/
engines/pmemblk.c
+++ b/
engines/pmemblk.c
@@
-1,5
+1,5
@@
/*
/*
- * pmemblk: IO engine that uses
NVML
libpmemblk to read and write data
+ * pmemblk: IO engine that uses
PMDK
libpmemblk to read and write data
*
* Copyright (C) 2016 Hewlett Packard Enterprise Development LP
*
*
* Copyright (C) 2016 Hewlett Packard Enterprise Development LP
*
@@
-14,8
+14,8
@@
*
* You should have received a copy of the GNU General Public
* License along with this program; if not, write to the Free
*
* You should have received a copy of the GNU General Public
* License along with this program; if not, write to the Free
- * Software Foundation, Inc., 5
9 Temple Place, Suite 330
,
- * Boston, MA 0211
1-1307 USA
+ * Software Foundation, Inc., 5
1 Franklin Street, Fifth Floor
,
+ * Boston, MA 0211
0-1301, USA.
*/
/*
*/
/*
@@
-86,10
+86,6
@@
struct fio_pmemblk_file {
size_t pmb_bsize;
size_t pmb_nblocks;
};
size_t pmb_bsize;
size_t pmb_nblocks;
};
-#define FIOFILEPMBSET(_f, _v) do { \
- (_f)->engine_data = (uint64_t)(uintptr_t)(_v); \
-} while(0)
-#define FIOFILEPMBGET(_f) ((fio_pmemblk_file_t)((_f)->engine_data))
static fio_pmemblk_file_t Cache;
static fio_pmemblk_file_t Cache;
@@
-304,26
+300,26
@@
static int fio_pmemblk_open_file(struct thread_data *td, struct fio_file *f)
if (!pmb)
return 1;
if (!pmb)
return 1;
- FI
OFILEPMBSET
(f, pmb);
+ FI
LE_SET_ENG_DATA
(f, pmb);
return 0;
}
static int fio_pmemblk_close_file(struct thread_data fio_unused *td,
struct fio_file *f)
{
return 0;
}
static int fio_pmemblk_close_file(struct thread_data fio_unused *td,
struct fio_file *f)
{
- fio_pmemblk_file_t pmb = FI
OFILEPMBGET
(f);
+ fio_pmemblk_file_t pmb = FI
LE_ENG_DATA
(f);
if (pmb)
pmb_close(pmb, false);
if (pmb)
pmb_close(pmb, false);
- FI
OFILEPMBSET
(f, NULL);
+ FI
LE_SET_ENG_DATA
(f, NULL);
return 0;
}
static int fio_pmemblk_get_file_size(struct thread_data *td, struct fio_file *f)
{
uint64_t flags = 0;
return 0;
}
static int fio_pmemblk_get_file_size(struct thread_data *td, struct fio_file *f)
{
uint64_t flags = 0;
- fio_pmemblk_file_t pmb = FI
OFILEPMBGET
(f);
+ fio_pmemblk_file_t pmb = FI
LE_ENG_DATA
(f);
if (fio_file_size_known(f))
return 0;
if (fio_file_size_known(f))
return 0;
@@
-340,16
+336,17
@@
static int fio_pmemblk_get_file_size(struct thread_data *td, struct fio_file *f)
fio_file_set_size_known(f);
fio_file_set_size_known(f);
- if (!FI
OFILEPMBGET
(f))
+ if (!FI
LE_ENG_DATA
(f))
pmb_close(pmb, true);
return 0;
}
pmb_close(pmb, true);
return 0;
}
-static int fio_pmemblk_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_pmemblk_queue(struct thread_data *td,
+ struct io_u *io_u)
{
struct fio_file *f = io_u->file;
{
struct fio_file *f = io_u->file;
- fio_pmemblk_file_t pmb = FI
OFILEPMBGET
(f);
+ fio_pmemblk_file_t pmb = FI
LE_ENG_DATA
(f);
unsigned long long off;
unsigned long len;
unsigned long long off;
unsigned long len;