diff options
author | Dan Williams <dan.j.williams@intel.com> | 2017-04-12 22:37:44 +0200 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2017-04-25 22:20:36 +0200 |
commit | 817bf40265459578abc36c6bd53e27775b5c7ec4 (patch) | |
tree | 7f77cc1bb97457d10d92df83a640d8d90023a653 /drivers/md/dm-target.c | |
parent | dm: add dax_device and dax_operations support (diff) | |
download | linux-817bf40265459578abc36c6bd53e27775b5c7ec4.tar.xz linux-817bf40265459578abc36c6bd53e27775b5c7ec4.zip |
dm: teach dm-targets to use a dax_device + dax_operations
Arrange for dm to lookup the dax services available from member devices.
Update the dax-capable targets, linear and stripe, to route dax
operations to the underlying device. Changes the target-internal
->direct_access() method to more closely align with the dax_operations
->direct_access() calling convention.
Cc: 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 'drivers/md/dm-target.c')
-rw-r--r-- | drivers/md/dm-target.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/md/dm-target.c b/drivers/md/dm-target.c index 43d3445b121d..6a7968f93f3c 100644 --- a/drivers/md/dm-target.c +++ b/drivers/md/dm-target.c @@ -142,8 +142,8 @@ static void io_err_release_clone_rq(struct request *clone) { } -static long io_err_direct_access(struct dm_target *ti, sector_t sector, - void **kaddr, pfn_t *pfn, long size) +static long io_err_dax_direct_access(struct dm_target *ti, pgoff_t pgoff, + long nr_pages, void **kaddr, pfn_t *pfn) { return -EIO; } @@ -157,7 +157,7 @@ static struct target_type error_target = { .map = io_err_map, .clone_and_map_rq = io_err_clone_and_map_rq, .release_clone_rq = io_err_release_clone_rq, - .direct_access = io_err_direct_access, + .direct_access = io_err_dax_direct_access, }; int __init dm_target_init(void) |