dax: add .recovery_write dax_operation
authorJane Chu <jane.chu@oracle.com>
Fri, 22 Apr 2022 22:45:06 +0000 (16:45 -0600)
committerDan Williams <dan.j.williams@intel.com>
Mon, 16 May 2022 20:37:59 +0000 (13:37 -0700)
commit047218ec904da19c45c4a70274fc3f818a1fcba1
tree6602586a5cbfa59b34a6699c920a0d4e7ad7dac8
parente511c4a3d2a1f64aafc1f5df37a2ffcf7ef91b55
dax: add .recovery_write dax_operation

Introduce dax_recovery_write() operation. The function is used to
recover a dax range that contains poison. Typical use case is when
a user process receives a SIGBUS with si_code BUS_MCEERR_AR
indicating poison(s) in a dax range, in response, the user process
issues a pwrite() to the page-aligned dax range, thus clears the
poison and puts valid data in the range.

Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jane Chu <jane.chu@oracle.com>
Link: https://lore.kernel.org/r/20220422224508.440670-6-jane.chu@oracle.com
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
drivers/dax/super.c
drivers/md/dm-linear.c
drivers/md/dm-log-writes.c
drivers/md/dm-stripe.c
drivers/md/dm.c
drivers/nvdimm/pmem.c
fs/dax.c
include/linux/dax.h
include/linux/device-mapper.h