summaryrefslogtreecommitdiffstats
path: root/drivers/nvdimm/nd-core.h
diff options
context:
space:
mode:
authorDan Williams2016-05-21 20:01:41 +0200
committerDan Williams2016-05-21 20:01:41 +0200
commit5e24c9fd36285535c704e84748d6c890be870fb6 (patch)
tree72482127094e47042d46d9e8892466852f0e5347 /drivers/nvdimm/nd-core.h
parentlibnvdimm, dax: autodetect support (diff)
downloadkernel-qcow2-linux-5e24c9fd36285535c704e84748d6c890be870fb6.tar.gz
kernel-qcow2-linux-5e24c9fd36285535c704e84748d6c890be870fb6.tar.xz
kernel-qcow2-linux-5e24c9fd36285535c704e84748d6c890be870fb6.zip
libnvdimm, dax: fix alignment validation
Testing the dax-device autodetect support revealed a probe failure with the following result: dax0.1: bad offset: 0x8200000 dax disabled The original pfn-device implementation inferred the alignment from ilog2(offset), now that the alignment is explicit the is_power_of_2() needs replacing with a real sanity check against the recorded alignment. Otherwise the alignment check is useless in the implicit case and only the minimum size of the offset matters. This self-consistency check is further validated by the probe path that will re-check that the offset is large enough to contain all the metadata required to enable the device. Cc: <stable@vger.kernel.org> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'drivers/nvdimm/nd-core.h')
0 files changed, 0 insertions, 0 deletions