aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2015-07-10 13:06:11 -0400
committerDan Williams <dan.j.williams@intel.com>2015-07-10 13:50:50 -0400
commitb1b2e6235a44174151fa3bb22657f74972635618 (patch)
treed4bc993420914f1be77a0b017d9dcac51f93ca58
parentb864bc17f1c326783f2388057e15d3e153125ab9 (diff)
tools/testing/nvdimm: mock ioremap_wt
In the 4.2-rc1 merge the default_memremap_pmem() implementation switched from ioremap_nocache() to ioremap_wt(). Add it to the list of mocked routines to restore the ability to run the unit tests. Signed-off-by: Dan Williams <dan.j.williams@intel.com>
-rw-r--r--tools/testing/nvdimm/Kbuild1
-rw-r--r--tools/testing/nvdimm/test/iomap.c6
2 files changed, 7 insertions, 0 deletions
diff --git a/tools/testing/nvdimm/Kbuild b/tools/testing/nvdimm/Kbuild
index 8e9b64520ec1..8e020601c773 100644
--- a/tools/testing/nvdimm/Kbuild
+++ b/tools/testing/nvdimm/Kbuild
@@ -1,3 +1,4 @@
1ldflags-y += --wrap=ioremap_wt
1ldflags-y += --wrap=ioremap_cache 2ldflags-y += --wrap=ioremap_cache
2ldflags-y += --wrap=ioremap_nocache 3ldflags-y += --wrap=ioremap_nocache
3ldflags-y += --wrap=iounmap 4ldflags-y += --wrap=iounmap
diff --git a/tools/testing/nvdimm/test/iomap.c b/tools/testing/nvdimm/test/iomap.c
index c85a6f6ba559..9f21b150396b 100644
--- a/tools/testing/nvdimm/test/iomap.c
+++ b/tools/testing/nvdimm/test/iomap.c
@@ -77,6 +77,12 @@ void __iomem *__wrap_ioremap_nocache(resource_size_t offset, unsigned long size)
77} 77}
78EXPORT_SYMBOL(__wrap_ioremap_nocache); 78EXPORT_SYMBOL(__wrap_ioremap_nocache);
79 79
80void __iomem *__wrap_ioremap_wt(resource_size_t offset, unsigned long size)
81{
82 return __nfit_test_ioremap(offset, size, ioremap_wt);
83}
84EXPORT_SYMBOL(__wrap_ioremap_wt);
85
80void __wrap_iounmap(volatile void __iomem *addr) 86void __wrap_iounmap(volatile void __iomem *addr)
81{ 87{
82 struct nfit_test_resource *nfit_res; 88 struct nfit_test_resource *nfit_res;