summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDave Jiang <dave.jiang@intel.com>2022-11-30 12:22:44 -0700
committerDan Williams <dan.j.williams@intel.com>2022-12-01 12:42:35 -0800
commitdcedadfae28562ad04bc351cabfbc0c65b810847 (patch)
treee16c310290851c1da761ec761b3d19aba3af2740 /include
parent9f01733387460ee373eb8da4292062ffc5fa340b (diff)
nvdimm/cxl/pmem: Add support for master passphrase disable security command
The original nvdimm_security_ops ->disable() only supports user passphrase for security disable. The CXL spec introduced the disabling of master passphrase. Add a ->disable_master() callback to support this new operation and leaving the old ->disable() mechanism alone. A "disable_master" command is added for the sysfs attribute in order to allow command to be issued from userspace. ndctl will need enabling in order to utilize this new operation. Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Signed-off-by: Dave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/166983616454.2734609.14204031148234398086.stgit@djiang5-desk3.ch.intel.com Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/libnvdimm.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/libnvdimm.h b/include/linux/libnvdimm.h
index c74acfa1a3fe..3bf658a74ccb 100644
--- a/include/linux/libnvdimm.h
+++ b/include/linux/libnvdimm.h
@@ -183,6 +183,8 @@ struct nvdimm_security_ops {
int (*overwrite)(struct nvdimm *nvdimm,
const struct nvdimm_key_data *key_data);
int (*query_overwrite)(struct nvdimm *nvdimm);
+ int (*disable_master)(struct nvdimm *nvdimm,
+ const struct nvdimm_key_data *key_data);
};
enum nvdimm_fwa_state {