summaryrefslogtreecommitdiff
path: root/include/linux/dax.h
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2017-05-29 12:57:56 -0700
committerDan Williams <dan.j.williams@intel.com>2017-06-09 09:22:21 -0700
commit7e026c8c0a4200da86bc51edeaad79dcdccf78ca (patch)
treeb1e30796161a6b1696ce75c2098d2fb980cb6a44 /include/linux/dax.h
parent0aed55af88345b5d673240f90e671d79662fb01e (diff)
dm: add ->copy_from_iter() dax operation support
Allow device-mapper to route copy_from_iter operations to the per-target implementation. In order for the device stacking to work we need a dax_dev and a pgoff relative to that device. This gives each layer of the stack the information it needs to look up the operation pointer for the next level. This conceptually allows for an array of mixed device drivers with varying copy_from_iter implementations. Reviewed-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Mike Snitzer <snitzer@redhat.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'include/linux/dax.h')
-rw-r--r--include/linux/dax.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/dax.h b/include/linux/dax.h
index bbe79ed90e2b..28e398f8c59e 100644
--- a/include/linux/dax.h
+++ b/include/linux/dax.h
@@ -78,6 +78,8 @@ void kill_dax(struct dax_device *dax_dev);
void *dax_get_private(struct dax_device *dax_dev);
long dax_direct_access(struct dax_device *dax_dev, pgoff_t pgoff, long nr_pages,
void **kaddr, pfn_t *pfn);
+size_t dax_copy_from_iter(struct dax_device *dax_dev, pgoff_t pgoff, void *addr,
+ size_t bytes, struct iov_iter *i);
/*
* We use lowest available bit in exceptional entry for locking, one bit for