diff options
author | Dan Williams <dan.j.williams@intel.com> | 2018-05-02 15:46:33 +0200 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2018-05-23 08:18:31 +0200 |
commit | b3a9a0c36e1f7b9e2e6cf965c2bb973624f2b3b9 (patch) | |
tree | 54f43a8720a29159310b112cf21e7d3a3b5dce85 /drivers/s390/block | |
parent | uio, lib: Fix CONFIG_ARCH_HAS_UACCESS_MCSAFE compilation (diff) | |
download | linux-b3a9a0c36e1f7b9e2e6cf965c2bb973624f2b3b9.tar.xz linux-b3a9a0c36e1f7b9e2e6cf965c2bb973624f2b3b9.zip |
dax: Introduce a ->copy_to_iter dax operation
Similar to the ->copy_from_iter() operation, a platform may want to
deploy an architecture or device specific routine for handling reads
from a dax_device like /dev/pmemX. On x86 this routine will point to a
machine check safe version of copy_to_iter(). For now, add the plumbing
to device-mapper and the dax core.
Cc: Ross Zwisler <ross.zwisler@linux.intel.com>
Cc: Mike Snitzer <snitzer@redhat.com>
Cc: Christoph Hellwig <hch@lst.de>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'drivers/s390/block')
-rw-r--r-- | drivers/s390/block/dcssblk.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/s390/block/dcssblk.c b/drivers/s390/block/dcssblk.c index 0a312e450207..29024492b8ed 100644 --- a/drivers/s390/block/dcssblk.c +++ b/drivers/s390/block/dcssblk.c @@ -51,9 +51,16 @@ static size_t dcssblk_dax_copy_from_iter(struct dax_device *dax_dev, return copy_from_iter(addr, bytes, i); } +static size_t dcssblk_dax_copy_to_iter(struct dax_device *dax_dev, + pgoff_t pgoff, void *addr, size_t bytes, struct iov_iter *i) +{ + return copy_to_iter(addr, bytes, i); +} + static const struct dax_operations dcssblk_dax_ops = { .direct_access = dcssblk_dax_direct_access, .copy_from_iter = dcssblk_dax_copy_from_iter, + .copy_to_iter = dcssblk_dax_copy_to_iter, }; struct dcssblk_dev_info { |