aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/acpi/nfit/nfit.h
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2017-10-29 12:13:07 -0700
committerDan Williams <dan.j.williams@intel.com>2017-10-29 12:13:07 -0700
commitb9b1504d3c6d6831c822cd785e095fc5fb155346 (patch)
tree3eb270e7ff9197a92df20f93ada3bbdb658bc7df /drivers/acpi/nfit/nfit.h
parentdev/dax: fix uninitialized variable build warning (diff)
downloadlinux-dev-b9b1504d3c6d6831c822cd785e095fc5fb155346.tar.xz
linux-dev-b9b1504d3c6d6831c822cd785e095fc5fb155346.zip
acpi, nfit: hide unknown commands from nmemX/commands
For vendor specific commands that do not have a common kernel translation, hide them from nmemX/commands. For example, the following results from new enabling to probe for support of the new NVDIMM_FAMILY_INTEL DSMs specified in v1.6 of the command specification [1]: # cat /sys/bus/nd/devices/nmem0/commands smart smart_thresh flags get_size get_data set_data effect_size effect_log vendor cmd_call unknown unknown unknown unknown unknown unknown unknown unknown [1]: https://pmem.io/documents/NVDIMM_DSM_Interface-V1.6.pdf Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to '')
-rw-r--r--drivers/acpi/nfit/nfit.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/acpi/nfit/nfit.h b/drivers/acpi/nfit/nfit.h
index 3976d649f27c..b987196bf132 100644
--- a/drivers/acpi/nfit/nfit.h
+++ b/drivers/acpi/nfit/nfit.h
@@ -38,6 +38,12 @@
| ACPI_NFIT_MEM_RESTORE_FAILED | ACPI_NFIT_MEM_FLUSH_FAILED \
| ACPI_NFIT_MEM_NOT_ARMED | ACPI_NFIT_MEM_MAP_FAILED)
+#define NVDIMM_STANDARD_CMDMASK \
+(1 << ND_CMD_SMART | 1 << ND_CMD_SMART_THRESHOLD | 1 << ND_CMD_DIMM_FLAGS \
+ | 1 << ND_CMD_GET_CONFIG_SIZE | 1 << ND_CMD_GET_CONFIG_DATA \
+ | 1 << ND_CMD_SET_CONFIG_DATA | 1 << ND_CMD_VENDOR_EFFECT_LOG_SIZE \
+ | 1 << ND_CMD_VENDOR_EFFECT_LOG | 1 << ND_CMD_VENDOR)
+
enum nfit_uuids {
/* for simplicity alias the uuid index with the family id */
NFIT_DEV_DIMM = NVDIMM_FAMILY_INTEL,