]> www.infradead.org Git - users/jedix/linux-maple.git/commit
pmem: add copy_from_iter_pmem() and clear_pmem()
authorRoss Zwisler <ross.zwisler@linux.intel.com>
Tue, 18 Aug 2015 19:55:39 +0000 (13:55 -0600)
committerDan Duval <dan.duval@oracle.com>
Wed, 7 Dec 2016 17:19:25 +0000 (12:19 -0500)
commit6d33a1203f9b9d62743650bb100a8cb70208bef2
tree0cb4fc6072f1d8460d668bc06e88ea300ea2359b
parent26eb0d08ab5a6894385657dda5b838d6bb68d0cc
pmem: add copy_from_iter_pmem() and clear_pmem()

Orabug: 22913653

Add support for two new PMEM APIs, copy_from_iter_pmem() and
clear_pmem().  copy_from_iter_pmem() is used to copy data from an
iterator into a PMEM buffer.  clear_pmem() zeros a PMEM memory range.

Both of these new APIs must be explicitly ordered using a wmb_pmem()
function call and are implemented in such a way that the wmb_pmem()
will make the stores to PMEM durable.  Because both APIs are unordered
they can be called as needed without introducing any unwanted memory
barriers.

Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
(cherry picked from commit 5de490daec8b6354b90d5c9d3e2415b195f5adb6)
Signed-off-by: Dan Duval <dan.duval@oracle.com>
arch/x86/include/asm/pmem.h
include/linux/pmem.h