diff options
author | Dan Williams <dan.j.williams@intel.com> | 2021-09-09 01:58:13 +0300 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2021-09-09 01:58:13 +0300 |
commit | 3fc3725357414636d91be1558ce8b14f228b4bda (patch) | |
tree | e16d052bfac4a5c2da1c9a16cb871e263bfeca3e /drivers/md | |
parent | 32b2397c1e56f33b0b1881def965bb89bd12f448 (diff) | |
parent | bdd3c50d83bf7f6acc869b48d02670d19030ae03 (diff) | |
download | linux-3fc3725357414636d91be1558ce8b14f228b4bda.tar.xz |
Merge branch 'for-5.15/fsdax-cleanups' into for-5.15/libnvdimm
Include Christoph's rework of the dax_supported() helpers in the v5.15
libnvdimm update. This supports the ongoing dax-reflink enabling effort.
Diffstat (limited to 'drivers/md')
-rw-r--r-- | drivers/md/dm-table.c | 9 | ||||
-rw-r--r-- | drivers/md/dm.c | 2 |
2 files changed, 3 insertions, 8 deletions
diff --git a/drivers/md/dm-table.c b/drivers/md/dm-table.c index 0543cdf89e92..b53acca37581 100644 --- a/drivers/md/dm-table.c +++ b/drivers/md/dm-table.c @@ -809,14 +809,9 @@ EXPORT_SYMBOL_GPL(dm_table_set_type); int device_not_dax_capable(struct dm_target *ti, struct dm_dev *dev, sector_t start, sector_t len, void *data) { - int blocksize = *(int *) data, id; - bool rc; + int blocksize = *(int *) data; - id = dax_read_lock(); - rc = !dax_supported(dev->dax_dev, dev->bdev, blocksize, start, len); - dax_read_unlock(id); - - return rc; + return !dax_supported(dev->dax_dev, dev->bdev, blocksize, start, len); } /* Check devices support synchronous DAX */ diff --git a/drivers/md/dm.c b/drivers/md/dm.c index 2c5f9e585211..465714341300 100644 --- a/drivers/md/dm.c +++ b/drivers/md/dm.c @@ -650,7 +650,7 @@ static int open_table_device(struct table_device *td, dev_t dev, } td->dm_dev.bdev = bdev; - td->dm_dev.dax_dev = dax_get_by_host(bdev->bd_disk->disk_name); + td->dm_dev.dax_dev = fs_dax_get_by_bdev(bdev); return 0; } |