]> git.baikalelectronics.ru Git - kernel.git/commit
acpi, nfit: fix bus vs dimm confusion in xlat_status
authorDan Williams <dan.j.williams@intel.com>
Tue, 6 Dec 2016 23:06:55 +0000 (15:06 -0800)
committerDan Williams <dan.j.williams@intel.com>
Wed, 7 Dec 2016 00:30:37 +0000 (16:30 -0800)
commit537562926e73dc14e840f3b50f4b284c246ddbc1
tree5ffbbc6b4585a5df44dc7d5b9017188469252684
parent95adcdde0d61623fc3b25f8e18081b72e2bce1ee
acpi, nfit: fix bus vs dimm confusion in xlat_status

Given dimms and bus commands share the same command number space we need
to be careful that we are translating status in the correct context.
Otherwise we can, for example, fail an ND_CMD_GET_CONFIG_SIZE command
because max_xfer is zero. It fails because that condition erroneously
correlates with the 'cleared == 0' failure of ND_CMD_CLEAR_ERROR.

Cc: <stable@vger.kernel.org>
Fixes: 3b6789d057e3 ("libnvdimm, nfit: centralize command status translation")
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
drivers/acpi/nfit/core.c