Commit 5f0694b3 authored by Dan Williams's avatar Dan Williams

device-dax: rename 'dax_dev' to 'dev_dax'

In preparation for introducing a struct dax_device type to the kernel
global type namespace, rename dax_dev to dev_dax. A 'dax_device'
instance will be a generic device-driver object for any provider of dax
functionality. A 'dev_dax' object is a device-dax-driver local /
internal instance.
Signed-off-by: default avatarDan Williams <dan.j.williams@intel.com>
parent 76202620
This diff is collapsed.
...@@ -13,13 +13,13 @@ ...@@ -13,13 +13,13 @@
#ifndef __DAX_H__ #ifndef __DAX_H__
#define __DAX_H__ #define __DAX_H__
struct device; struct device;
struct dax_dev; struct dev_dax;
struct resource; struct resource;
struct dax_region; struct dax_region;
void dax_region_put(struct dax_region *dax_region); void dax_region_put(struct dax_region *dax_region);
struct dax_region *alloc_dax_region(struct device *parent, struct dax_region *alloc_dax_region(struct device *parent,
int region_id, struct resource *res, unsigned int align, int region_id, struct resource *res, unsigned int align,
void *addr, unsigned long flags); void *addr, unsigned long flags);
struct dax_dev *devm_create_dax_dev(struct dax_region *dax_region, struct dev_dax *devm_create_dev_dax(struct dax_region *dax_region,
struct resource *res, int count); struct resource *res, int count);
#endif /* __DAX_H__ */ #endif /* __DAX_H__ */
...@@ -61,8 +61,8 @@ static int dax_pmem_probe(struct device *dev) ...@@ -61,8 +61,8 @@ static int dax_pmem_probe(struct device *dev)
int rc; int rc;
void *addr; void *addr;
struct resource res; struct resource res;
struct dax_dev *dax_dev;
struct nd_pfn_sb *pfn_sb; struct nd_pfn_sb *pfn_sb;
struct dev_dax *dev_dax;
struct dax_pmem *dax_pmem; struct dax_pmem *dax_pmem;
struct nd_region *nd_region; struct nd_region *nd_region;
struct nd_namespace_io *nsio; struct nd_namespace_io *nsio;
...@@ -130,12 +130,12 @@ static int dax_pmem_probe(struct device *dev) ...@@ -130,12 +130,12 @@ static int dax_pmem_probe(struct device *dev)
return -ENOMEM; return -ENOMEM;
/* TODO: support for subdividing a dax region... */ /* TODO: support for subdividing a dax region... */
dax_dev = devm_create_dax_dev(dax_region, &res, 1); dev_dax = devm_create_dev_dax(dax_region, &res, 1);
/* child dax_dev instances now own the lifetime of the dax_region */ /* child dev_dax instances now own the lifetime of the dax_region */
dax_region_put(dax_region); dax_region_put(dax_region);
return PTR_ERR_OR_ZERO(dax_dev); return PTR_ERR_OR_ZERO(dev_dax);
} }
static struct nd_device_driver dax_pmem_driver = { static struct nd_device_driver dax_pmem_driver = {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment