summaryrefslogtreecommitdiff
path: root/include/linux/libnvdimm.h
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2022-12-02 01:03:35 +0300
committerDan Williams <dan.j.williams@intel.com>2022-12-03 10:52:32 +0300
commitdc370b28c8425669e7ed5af4c01540645cfb00ec (patch)
tree37e58358cc8be8750eca80a2342e7459d25c9464 /include/linux/libnvdimm.h
parent07cb5f705b4fe9e1386a610da4cb3c063267714f (diff)
downloadlinux-dc370b28c8425669e7ed5af4c01540645cfb00ec.tar.xz
nvdimm/region: Move cache management to the region driver
Now that cpu_cache_invalidate_memregion() is generically available, use it to centralize CPU cache management in the nvdimm region driver. This trades off removing redundant per-dimm CPU cache flushing with an opportunistic flush on every region disable event to cover the case of sensitive dirty data in the cache being written back to media after a secure erase / overwrite event. Reviewed-by: Davidlohr Bueso <dave@stgolabs.net> Reviewed-by: Dave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/166993221550.1995348.16843505129579060258.stgit@dwillia2-xfh.jf.intel.com Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'include/linux/libnvdimm.h')
-rw-r--r--include/linux/libnvdimm.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/libnvdimm.h b/include/linux/libnvdimm.h
index 3bf658a74ccb..af38252ad704 100644
--- a/include/linux/libnvdimm.h
+++ b/include/linux/libnvdimm.h
@@ -35,6 +35,11 @@ enum {
NDD_WORK_PENDING = 4,
/* dimm supports namespace labels */
NDD_LABELING = 6,
+ /*
+ * dimm contents have changed requiring invalidation of CPU caches prior
+ * to activation of a region that includes this device
+ */
+ NDD_INCOHERENT = 7,
/* need to set a limit somewhere, but yes, this is likely overkill */
ND_IOCTL_MAX_BUFLEN = SZ_4M,