[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <147131793557.13727.4080875938782302791.stgit@dwillia2-desk3.amr.corp.intel.com>
Date: Mon, 15 Aug 2016 20:25:35 -0700
From: Dan Williams <dan.j.williams@...el.com>
To: linux-nvdimm@...ts.01.org
Cc: linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org,
viro@...iv.linux.org.uk
Subject: [PATCH 7/7] 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@...el.com>
---
drivers/dax/dax.c | 1 +
1 file changed, 1 insertion(+)
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);
}
Powered by blists - more mailing lists