diff options
author | Dan Williams <dan.j.williams@intel.com> | 2016-08-04 16:53:50 -0700 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2016-08-23 22:58:51 -0700 |
commit | 9dc1e4927bfabaf654738c9ecca3a4926a0aaeb5 (patch) | |
tree | 6a8eb0625e290f6cecd71900c47345d63791d8f4 /drivers/dax | |
parent | 3bc52c45bac26bf7ed1dc8d287ad1aeaed1250b6 (diff) | |
download | linux-9dc1e4927bfabaf654738c9ecca3a4926a0aaeb5.tar.bz2 |
dax: unmap/truncate on device shutdown
Invalidate all mappings of a device-dax instance when the device is
unregistered.
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'drivers/dax')
-rw-r--r-- | drivers/dax/dax.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/dax/dax.c b/drivers/dax/dax.c index e8b9319aeadb..0a7899d5c65c 100644 --- a/drivers/dax/dax.c +++ b/drivers/dax/dax.c @@ -550,6 +550,7 @@ static void unregister_dax_dev(void *dev) */ dax_dev->alive = false; synchronize_rcu(); + unmap_mapping_range(dax_dev->inode->i_mapping, 0, 0, 1); cdev_del(cdev); device_unregister(dev); } |