summaryrefslogtreecommitdiff
path: root/tools/testing/nvdimm/test/iomap.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/testing/nvdimm/test/iomap.c')
-rw-r--r--tools/testing/nvdimm/test/iomap.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/tools/testing/nvdimm/test/iomap.c b/tools/testing/nvdimm/test/iomap.c
index 076df22e4bda..cf3f064a697d 100644
--- a/tools/testing/nvdimm/test/iomap.c
+++ b/tools/testing/nvdimm/test/iomap.c
@@ -100,9 +100,10 @@ static void nfit_test_kill(void *_pgmap)
{
struct dev_pagemap *pgmap = _pgmap;
- WARN_ON(!pgmap || !pgmap->ref || !pgmap->kill || !pgmap->cleanup);
- pgmap->kill(pgmap->ref);
- pgmap->cleanup(pgmap->ref);
+ WARN_ON(!pgmap || !pgmap->ref || !pgmap->ops || !pgmap->ops->kill ||
+ !pgmap->ops->cleanup);
+ pgmap->ops->kill(pgmap->ref);
+ pgmap->ops->cleanup(pgmap->ref);
}
void *__wrap_devm_memremap_pages(struct device *dev, struct dev_pagemap *pgmap)