]> git.baikalelectronics.ru Git - kernel.git/commit
pmem: report error on clear poison failure
authorToshi Kani <toshi.kani@hpe.com>
Thu, 13 Oct 2016 15:54:21 +0000 (09:54 -0600)
committerDan Williams <dan.j.williams@intel.com>
Wed, 19 Oct 2016 17:35:52 +0000 (10:35 -0700)
commit30ef564b1d91b37d700f758d736bb75a5c360c26
tree975efbbc07264df4bc1e454203da10852b521f88
parent778b761d886dd14ecedf312ce146e499e51b2772
pmem: report error on clear poison failure

ACPI Clear Uncorrectable Error DSM function may fail or may be
unsupported on a platform.  pmem_clear_poison() returns without clearing
badblocks in such cases.  This failure is detected at the next read
(-EIO).

This behavior can lead to an issue when user keeps writing but does not
read immediately.  For instance, flight recorder file may be only read
when it is necessary for troubleshooting.

Change pmem_do_bvec() and pmem_clear_poison() to return -EIO so that
filesystem can log an error message on a write error.

Cc: Vishal Verma <vishal.l.verma@intel.com>
Signed-off-by: Toshi Kani <toshi.kani@hpe.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
drivers/nvdimm/pmem.c