[PATCH v2 0/2] libnvdimm: export wpq flush interface

From: Dan Williams
Date: Mon Apr 24 2017 - 19:56:03 EST


Changes since v1 [1]:
* Clean up the changelog to clarify how this capability is expected to
be used (Jeff)
* Make the attribute read / write to separate detection and flush
triggering (Masayoshi)
* Add the flush hint detection crash fix

[1]: https://lists.01.org/pipermail/linux-nvdimm/2017-April/009898.html

---

Quoting the changelog from patch2:

The nvdimm_flush() mechanism helps to reduce the impact of an ADR
(asynchronous-dimm-refresh) failure. The ADR mechanism handles flushing
platform WPQ (write-pending-queue) buffers when power is removed. The
nvdimm_flush() mechanism performs that same function on-demand.

When a pmem namespace is associated with a block device, an
nvdimm_flush() is triggered with every block-layer REQ_FUA, or REQ_FLUSH
request. These requests are typically associated with filesystem
metadata updates. However, when a namespace is in device-dax mode,
userspace (think database metadata) needs another path to perform the
same flushing. In other words this is not required to make data
persistent, but in the case of metadata it allows for a smaller failure
domain in the unlikely event of an ADR failure.

---

Dan Williams (2):
libnvdimm, region: fix flush hint detection crash
libnvdimm, region: sysfs trigger for nvdimm_flush()


drivers/nvdimm/region_devs.c | 52 +++++++++++++++++++++++++++++++++++++++---
1 file changed, 48 insertions(+), 4 deletions(-)