linux-next/drivers/nvdimm
Dan Williams 7bf7eac8d6 dax: Arrange for dax_supported check to span multiple devices
Pankaj reports that starting with commit ad428cdb52 "dax: Check the
end of the block-device capacity with dax_direct_access()" device-mapper
no longer allows dax operation. This results from the stricter checks in
__bdev_dax_supported() that validate that the start and end of a
block-device map to the same 'pagemap' instance.

Teach the dax-core and device-mapper to validate the 'pagemap' on a
per-target basis. This is accomplished by refactoring the
bdev_dax_supported() internals into generic_fsdax_supported() which
takes a sector range to validate. Consequently generic_fsdax_supported()
is suitable to be used in a device-mapper ->iterate_devices() callback.
A new ->dax_supported() operation is added to allow composite devices to
split and route upper-level bdev_dax_supported() requests.

Fixes: ad428cdb52 ("dax: Check the end of the block-device...")
Cc: <stable@vger.kernel.org>
Cc: Ira Weiny <ira.weiny@intel.com>
Cc: Dave Jiang <dave.jiang@intel.com>
Cc: Keith Busch <keith.busch@intel.com>
Cc: Matthew Wilcox <willy@infradead.org>
Cc: Vishal Verma <vishal.l.verma@intel.com>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Reviewed-by: Jan Kara <jack@suse.cz>
Reported-by: Pankaj Gupta <pagupta@redhat.com>
Reviewed-by: Pankaj Gupta <pagupta@redhat.com>
Tested-by: Pankaj Gupta <pagupta@redhat.com>
Tested-by: Vaibhav Jain <vaibhav@linux.ibm.com>
Reviewed-by: Mike Snitzer <snitzer@redhat.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
2019-05-20 15:02:08 -07:00
..
badrange.c libnvdimm, badrange: remove a WARN for list_empty 2017-11-02 10:42:30 -07:00
blk.c block: genhd: add 'groups' argument to device_add_disk 2018-09-28 08:30:28 -06:00
btt_devs.c libnvdimm/btt: Fix a kmemdup failure check 2019-03-27 10:08:55 -07:00
btt.c libnvdimm/btt: Fix LBA masking during 'free list' population 2019-02-28 09:57:39 -08:00
btt.h libnvdimm/btt: Fix LBA masking during 'free list' population 2019-02-28 09:57:39 -08:00
bus.c libnvdimm: Fix compilation warnings with W=1 2019-05-20 15:02:08 -07:00
claim.c libnvdimm, pmem: Fix memcpy_mcsafe() return code handling in nsio_rw_bytes() 2018-06-28 18:21:30 -07:00
core.c libnvdimm: remove redundant __func__ in dev_dbg 2018-03-06 08:44:17 -08:00
dax_devs.c libnvdimm: remove redundant __func__ in dev_dbg 2018-03-06 08:44:17 -08:00
dimm_devs.c Printk changes for 5.2 2019-05-07 09:18:12 -07:00
dimm.c libnvdimm/security: Require nvdimm_security_setup_events() to succeed 2019-01-21 09:57:43 -08:00
e820.c acpi/nfit, device-dax: Identify differentiated memory with a unique numa-node 2019-01-06 21:41:57 -08:00
Kconfig acpi/nfit, libnvdimm: Add unlock of nvdimm support for Intel DIMMs 2018-12-13 17:54:13 -08:00
label.c libnvdimm: Fix compilation warnings with W=1 2019-05-20 15:02:08 -07:00
label.h libnvdimm: Fix compilation warnings with W=1 2019-05-20 15:02:08 -07:00
Makefile acpi/nfit, libnvdimm: Add unlock of nvdimm support for Intel DIMMs 2018-12-13 17:54:13 -08:00
namespace_devs.c libnvdimm/namespace: Fix label tracking error 2019-04-30 21:51:21 -07:00
nd-core.h libnvdimm/security: Fix nvdimm_security_state() state request selection 2019-01-15 13:54:33 -08:00
nd.h libnvdimm/namespace: Fix label tracking error 2019-04-30 21:51:21 -07:00
of_pmem.c device-dax for 5.1 2019-03-16 13:05:32 -07:00
pfn_devs.c block: remove CONFIG_LBDAF 2019-04-06 10:48:35 -06:00
pfn.h libnvdimm, dax: autodetect support 2016-05-20 22:02:57 -07:00
pmem.c dax: Arrange for dax_supported check to span multiple devices 2019-05-20 15:02:08 -07:00
pmem.h libnvdimm, pmem: Restore page attributes when clearing errors 2018-08-20 09:22:45 -07:00
region_devs.c device-dax for 5.1 2019-03-16 13:05:32 -07:00
region.c libnvdimm, region: quiet region probe 2018-04-07 07:47:10 -07:00
security.c libnvdimm/security, acpi/nfit: unify zero-key for all security commands 2019-03-30 08:27:07 -07:00