summaryrefslogtreecommitdiffstats
path: root/drivers/nvdimm/bus.c
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2016-07-22 05:03:19 +0200
committerDan Williams <dan.j.williams@intel.com>2016-07-22 05:03:19 +0200
commitbc9775d8697f57b333b6b316fb5145d6ca9dc36d (patch)
tree2eea64bed76f443a644ff078d2b2413a1dde29ce /drivers/nvdimm/bus.c
parentnfit: cleanup acpi_nfit_init calling convention (diff)
downloadlinux-bc9775d8697f57b333b6b316fb5145d6ca9dc36d.tar.xz
linux-bc9775d8697f57b333b6b316fb5145d6ca9dc36d.zip
libnvdimm: move ->module to struct nvdimm_bus_descriptor
Let the provider module be explicitly passed in rather than implicitly assumed by the module that calls nvdimm_bus_register(). This is in preparation for unifying the nfit and nfit_test driver teardown paths. Reviewed-by: Lee, Chun-Yi <jlee@suse.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'drivers/nvdimm/bus.c')
-rw-r--r--drivers/nvdimm/bus.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/nvdimm/bus.c b/drivers/nvdimm/bus.c
index 1cc7880320fe..275dd5c0a301 100644
--- a/drivers/nvdimm/bus.c
+++ b/drivers/nvdimm/bus.c
@@ -73,7 +73,7 @@ static struct module *to_bus_provider(struct device *dev)
if (is_nd_pmem(dev) || is_nd_blk(dev)) {
struct nvdimm_bus *nvdimm_bus = walk_to_nvdimm_bus(dev);
- return nvdimm_bus->module;
+ return nvdimm_bus->nd_desc->module;
}
return NULL;
}