Re: [PATCH] MAINTAINERS: Update filesystem-dax and NVDIMM entries

2019-01-24 Thread Ross Zwisler
l requests. > > > > Ira and Keith are now involved with the NVDIMM and Device-DAX > > sub-systems. > > > > The linux-nvdimm mailing hosts a patchwork instance for both DAX and > > NVDIMM patches. > > > > Cc: Jan Kara > > Cc: Ira Weiny > > C

Re: [PATCH v2 2/2] [PATCH] xfs: Close race between direct IO and xfs_break_layouts()

2018-08-10 Thread Ross Zwisler
On Fri, Aug 10, 2018 at 9:23 AM Dave Jiang wrote: > On 08/10/2018 11:31 AM, Eric Sandeen wrote: > > On 8/8/18 12:31 PM, Dave Jiang wrote: > >> This patch is the duplicate of ross's fix for ext4 for xfs. > >> > >> If the refcount of a page is lowered between the time that it is returned > >> by

Re: [PATCH v4 0/2] ext4: fix DAX dma vs truncate/hole-punch

2018-07-31 Thread Ross Zwisler
On Tue, Jul 10, 2018 at 01:10:29PM -0600, Ross Zwisler wrote: > Changes since v3: > * Added an ext4_break_layouts() call to ext4_insert_range() to ensure >that the {ext4,xfs}_break_layouts() calls have the same meaning. >(Dave, Darrick and Jan) > > --- > &

Re: Help trying to use /dev/pmem for dax debugging?

2018-07-31 Thread Ross Zwisler
On Mon, Jul 30, 2018 at 07:53:12PM -0400, Theodore Y. Ts'o wrote: > In newer kernels, it looks like you can't use /dev/pmem0 for DAX > unless it's marked as being DAX capable. This appears to require > CONFIG_NVDIMM_PFN. But when I tried to build a kernel with that > configured, I get the

[fstests PATCH v3] generic/999: test DAX DMA vs truncate/hole-punch

2018-07-27 Thread Ross Zwisler
From: Ross Zwisler This adds a regression test for the following series: https://lists.01.org/pipermail/linux-nvdimm/2018-July/016842.html which adds synchronization between DAX DMA in ext4 and truncate/hole-punch. The intention of the test is to test those specific changes, but it runs fine

Re: [PATCH v4 0/2] ext4: fix DAX dma vs truncate/hole-punch

2018-07-27 Thread Ross Zwisler
+ fsdevel and the xfs list. On Wed, Jul 25, 2018 at 4:28 PM Ross Zwisler wrote: > On Wed, Jul 11, 2018 at 10:17:41AM +0200, Jan Kara wrote: > > On Tue 10-07-18 13:10:29, Ross Zwisler wrote: > > > Changes since v3: > > > * Added an ext4_break_layouts() call to ex

Re: [PATCH v4 0/2] ext4: fix DAX dma vs truncate/hole-punch

2018-07-25 Thread Ross Zwisler
On Wed, Jul 11, 2018 at 10:17:41AM +0200, Jan Kara wrote: > On Tue 10-07-18 13:10:29, Ross Zwisler wrote: > > Changes since v3: > > * Added an ext4_break_layouts() call to ext4_insert_range() to ensure > >that the {ext4,xfs}_break_layouts() calls have the same meaning.

Re: [PATCH v2 0/6] kaddr and pfn can be NULL to ->direct_access()

2018-07-25 Thread Ross Zwisler
at > is to say callers may have no need for kaddr or pfn, so this series of > patch are prepared for allowing them to pass in NULL instead of having > to pass in a local pointer or variable that they then just throw away. Looks good. For the series: Reviewed-by: Ross Zwisler __

Re: [PATCH 0/5] Do not request a pointer kaddr when not required

2018-07-24 Thread Ross Zwisler
On Tue, Jul 24, 2018 at 04:45:05PM +0800, Huaisheng Ye wrote: > From: Huaisheng Ye > > Some functions within fs/dax and dax/super don't need to get kaddr from > direct_access. Assigning NULL to kaddr to ->direct_access() is more > straightforward and simple than offering a useless local pointer.

Re: [PATCH 1/5] radix tree test suite: fix mapshift build target

2018-07-21 Thread Ross Zwisler
On Sun, Jul 22, 2018 at 09:45:50AM +1000, Dave Chinner wrote: > On Mon, Jul 16, 2018 at 07:41:32PM -0700, Matthew Wilcox wrote: > > On Mon, Jul 16, 2018 at 03:08:20PM -0600, Ross Zwisler wrote: > > > On Mon, Jul 16, 2018 at 12:52:49PM -0700, Matthew Wilcox wrote: > > > &

Re: [ndctl PATCH] Documentation, create-namespace: clarify fsdax wording

2018-07-19 Thread Ross Zwisler
will use the page > + cache. See "devdax" mode for raw device access that supports > + dax. Looks good, you can add: Reviewed-by: Ross Zwisler ___ Linux-nvdimm mailing list Linux-nvdimm@lists.01.org https://lists.01.org/mailman/listinfo/linux-nvdimm

[PATCH 2/2] MAINTAINERS: Add Jan Kara for filesystem DAX

2018-07-19 Thread Ross Zwisler
Jan has been developing and reviewing filesystem DAX related changes for quite a while now, and has agreed to help maintain this code going forward. Thanks, Jan! Signed-off-by: Ross Zwisler Cc: Jan Kara --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b

[PATCH 0/2] Update mail addresses, add FS DAX maintainer

2018-07-19 Thread Ross Zwisler
window. Ross Zwisler (2): MAINTAINERS: update Ross Zwisler's email address MAINTAINERS: Add Jan Kara for filesystem DAX .mailmap| 1 + MAINTAINERS | 13 +++-- 2 files changed, 8 insertions(+), 6 deletions(-) -- 2.14.4 ___ Linux-nvdimm

Re: [PATCH 1/5] radix tree test suite: fix mapshift build target

2018-07-17 Thread Ross Zwisler
On Mon, Jul 16, 2018 at 08:18:11PM -0700, Matthew Wilcox wrote: > On Mon, Jul 16, 2018 at 10:07:10AM -0600, Ross Zwisler wrote: > > Incidentally, in the current linux/master the radix tree test suite again > > fails to build: > > > > $ make > > sed -e 's/

Re: [PATCH 1/5] radix tree test suite: fix mapshift build target

2018-07-16 Thread Ross Zwisler
On Mon, Jul 16, 2018 at 12:52:49PM -0700, Matthew Wilcox wrote: > On Mon, Jul 16, 2018 at 10:07:10AM -0600, Ross Zwisler wrote: <> > OK ... what version of make are you using? Because this works fine for me: > > $ git clone linux clean > $ cd clean > $ git checkout v4

Re: [PATCH 1/5] radix tree test suite: fix mapshift build target

2018-07-16 Thread Ross Zwisler
On Sun, Jul 15, 2018 at 04:00:52PM -0700, Matthew Wilcox wrote: > On Thu, May 03, 2018 at 01:24:26PM -0600, Ross Zwisler wrote: > > The following commit > > > > commit c6ce3e2fe3da ("radix tree test suite: Add config option for map > > shift") > &

Re: [ndctl PATCH 1/2] ndctl, test: fix tests for the array vs object listing fix

2018-07-12 Thread Ross Zwisler
mit by simply performing the test/common conversion. > > Fixes: 72c46ab194d9 ("ndctl list: always output array without --human") > Cc: Ross Zwisler > Cc: Dan Williams > Signed-off-by: Vishal Verma Nice, thanks for the fixes. __

Re: [PATCH v4 0/2] ext4: fix DAX dma vs truncate/hole-punch

2018-07-11 Thread Ross Zwisler
On Wed, Jul 11, 2018 at 10:17:41AM +0200, Jan Kara wrote: > On Tue 10-07-18 13:10:29, Ross Zwisler wrote: > > Changes since v3: > > * Added an ext4_break_layouts() call to ext4_insert_range() to ensure > >that the {ext4,xfs}_break_layouts() calls have the same meaning.

Re: [ndctl PATCHv3] ndctl: Add 'list' verbose options

2018-07-10 Thread Ross Zwisler
(jobj) > + if (jobj && flags & UTIL_JSON_VERBOSE) > json_object_object_add(jregion, "numa_node", jobj); > } This same change needs to be repeated in the other place where we print the numa_node, in util_namespace_to_json(). The rest looks good. You can add: Revi

[fstests PATCH v2 2/2] generic/999: test DAX DMA vs truncate/hole-punch

2018-07-10 Thread Ross Zwisler
you change this to a WARN_ON() instead, you can see that each of the four paths being exercised in this test hits that condition many times in the one second that the subtest is being run. Signed-off-by: Ross Zwisler --- .gitignore | 1 + src/Makefile | 2 +- src/t_mmap_

[fstests PATCH v2 1/2] src/: add license and copyright info to files

2018-07-10 Thread Ross Zwisler
Add copyright and license info to files that I've authored in src/. Signed-off-by: Ross Zwisler --- src/t_ext4_dax_inline_corruption.c | 2 ++ src/t_ext4_dax_journal_corruption.c | 2 ++ src/t_mmap_cow_race.c | 2 ++ src/t_mmap_stale_pmd.c | 2 ++ 4 files changed, 8

[fstests PATCH v2 0/2] Add test for DAX+ext4+DMA race

2018-07-10 Thread Ross Zwisler
to the punch, collapse and zero groups. (Eryu) Ross Zwisler (2): src/: add license and copyright info to files generic/999: test DAX DMA vs truncate/hole-punch .gitignore | 1 + src/Makefile| 2 +- src/t_ext4_dax_inline_corruption.c | 2 + src

Re: [fstests PATCH 2/2] generic/999: test DAX DMA vs truncate/hole-punch

2018-07-10 Thread Ross Zwisler
On Thu, Jun 21, 2018 at 10:40:33AM +0800, Eryu Guan wrote: > On Wed, Jun 20, 2018 at 04:51:47PM -0600, Ross Zwisler wrote: <> > > diff --git a/tests/generic/999 b/tests/generic/999 > > new file mode 100755 > > index ..8f488cb5 > > --- /dev/null > &

[PATCH v4 2/2] ext4: handle layout changes to pinned DAX mappings

2018-07-10 Thread Ross Zwisler
Follow the lead of xfs_break_dax_layouts() and add synchronization between operations in ext4 which remove blocks from an inode (hole punch, truncate down, etc.) and pages which are pinned due to DAX DMA operations. Signed-off-by: Ross Zwisler Reviewed-by: Jan Kara Reviewed-by: Lukas Czerner

[PATCH v4 1/2] dax: dax_layout_busy_page() warn on !exceptional

2018-07-10 Thread Ross Zwisler
-by: Ross Zwisler Reviewed-by: Jan Kara --- fs/dax.c | 10 +- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/fs/dax.c b/fs/dax.c index 641192808bb6..897b51e41d8f 100644 --- a/fs/dax.c +++ b/fs/dax.c @@ -566,7 +566,8 @@ struct page *dax_layout_busy_page(struct address_space

[PATCH v4 0/2] ext4: fix DAX dma vs truncate/hole-punch

2018-07-10 Thread Ross Zwisler
f the above WARN_ON_ONCE(), which tells me that we still have some work to do. I'll continue looking at these more rare hits. Ross Zwisler (2): dax: dax_layout_busy_page() warn on !exceptional ext4: handle layout changes to pinned DAX mappings fs/dax.c | 10 +- fs/ext4/ext4

[PATCH v2] mm/sparse.c: fix error path in sparse_add_one_section

2018-07-06 Thread Ross Zwisler
x230/0x680 worker_thread+0x3f/0x3b0 kthread+0x12f/0x150 ? process_one_work+0x680/0x680 ? kthread_create_worker_on_cpu+0x70/0x70 ret_from_fork+0x3a/0x50 Fix this by clearing 'ret' back to 0 if sparse_index_init() returns -EEXIST. This restores the previous behavior. Signed-off-by: Ro

Re: [PATCH] mm/sparse.c: fix error path in sparse_add_one_section

2018-07-06 Thread Ross Zwisler
On Fri, Jul 06, 2018 at 11:23:27PM +0200, Oscar Salvador wrote: > On Fri, Jul 06, 2018 at 01:06:58PM -0600, Ross Zwisler wrote: > > The following commit in -next: > > > > commit 054620849110 ("mm/sparse.c: make sparse_init_one_section void and > > remove check&

[PATCH] mm/sparse.c: fix error path in sparse_add_one_section

2018-07-06 Thread Ross Zwisler
x230/0x680 worker_thread+0x3f/0x3b0 kthread+0x12f/0x150 ? process_one_work+0x680/0x680 ? kthread_create_worker_on_cpu+0x70/0x70 ret_from_fork+0x3a/0x50 Fix this by clearing 'ret' back to 0 if sparse_index_init() returns -EEXIST. This restores the previous behavior. Signed-off-by: Ro

Re: [PATCH] mm/sparse: Make sparse_init_one_section void and remove check

2018-07-06 Thread Ross Zwisler
On Mon, Jul 2, 2018 at 12:48 PM Pavel Tatashin wrote: > > On Mon, Jul 2, 2018 at 11:43 AM wrote: > > > > From: Oscar Salvador > > > > sparse_init_one_section() is being called from two sites: > > sparse_init() and sparse_add_one_section(). > > The former calls it from a

[PATCH] nvdimm docs: remove reference to CONFIG_NFIT_TEST

2018-07-05 Thread Ross Zwisler
This symbol doesn't currently exist. The instructions on how to compile & load nfit_test are here: https://github.com/pmem/ndctl Signed-off-by: Ross Zwisler --- Documentation/nvdimm/nvdimm.txt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Documentation/nv

Re: [PATCH v3 2/2] ext4: handle layout changes to pinned DAX mappings

2018-07-05 Thread Ross Zwisler
; > truncate > > > > > down, etc.) and pages which are pinned due to DAX DMA operations. > > > > > > > > > > Signed-off-by: Ross Zwisler > > > > > Reviewed-by: Jan Kara > > > > > Reviewed-by: Lukas Czerner > >

Re: [PATCH v2 1/2] dax: dax_layout_busy_page() warn on !exceptional

2018-07-03 Thread Ross Zwisler
On Mon, Jul 02, 2018 at 06:15:03PM -0400, Theodore Y. Ts'o wrote: > On Wed, Jun 27, 2018 at 03:22:51PM -0600, Ross Zwisler wrote: > > Inodes using DAX should only ever have exceptional entries in their page > > caches. Make this clear by warning if the iteration in > > dax_la

[PATCH v3 2/2] ext4: handle layout changes to pinned DAX mappings

2018-07-02 Thread Ross Zwisler
Follow the lead of xfs_break_dax_layouts() and add synchronization between operations in ext4 which remove blocks from an inode (hole punch, truncate down, etc.) and pages which are pinned due to DAX DMA operations. Signed-off-by: Ross Zwisler Reviewed-by: Jan Kara Reviewed-by: Lukas Czerner

Re: [PATCH v2 2/2] ext4: handle layout changes to pinned DAX mappings

2018-07-02 Thread Ross Zwisler
On Mon, Jul 02, 2018 at 09:59:48AM +0200, Lukas Czerner wrote: > On Fri, Jun 29, 2018 at 09:13:00AM -0600, Ross Zwisler wrote: > > On Fri, Jun 29, 2018 at 02:02:23PM +0200, Lukas Czerner wrote: > > > On Wed, Jun 27, 2018 at 03:22:52PM -0600, Ross Zwisler wrote: >

[ndctl PATCH v2 2/2] ndctl list: always output array without --human

2018-06-29 Thread Ross Zwisler
ngle element which is not part of an array. Signed-off-by: Ross Zwisler --- daxctl/list.c| 11 +++ ndctl/bus.c | 2 +- ndctl/dimm.c | 2 +- ndctl/inject-smart.c | 2 +- ndctl/list.c | 8 util/json.c | 5 +++-- util/json.h

[ndctl PATCH v2 1/2] ndctl: simplify JSON print flag handling

2018-06-29 Thread Ross Zwisler
varied. Instead, just pass in the necessary flag when calling json_object_to_json_string_ext(), removing the local variables and the extra argument to util_display_json_array(). Signed-off-by: Ross Zwisler Acked-by: Dan Williams --- daxctl/list.c| 5 ++--- ndctl/bus.c | 3

[ndctl PATCH v2 0/2] always output array without --human

2018-06-29 Thread Ross Zwisler
* Added Dan's Ack to patch 1. Ross Zwisler (2): ndctl: simplify JSON print flag handling ndctl list: always output array without --human daxctl/list.c| 12 +++- ndctl/bus.c | 3 +-- ndctl/dimm.c | 3 +-- ndctl/inject-smart.c | 3 +-- ndctl/list.c

Re: [ndctl PATCH 2/3] ndctl/list.c: simplify flags handling

2018-06-29 Thread Ross Zwisler
On Fri, Jun 29, 2018 at 04:57:29PM -0700, Dan Williams wrote: > On Fri, Jun 29, 2018 at 4:39 PM, Ross Zwisler > wrote: > > ndctl/list.c keeps track of a set of enum util_json_flags which are based > > on the command line options passed in. This handling is a little messy, &g

[ndctl PATCH 3/3] ndctl list: always output array without --human

2018-06-29 Thread Ross Zwisler
ngle element which is not part of an array. Signed-off-by: Ross Zwisler --- daxctl/list.c| 11 +++ ndctl/bus.c | 2 +- ndctl/dimm.c | 2 +- ndctl/inject-smart.c | 2 +- ndctl/list.c | 8 util/json.c | 5 +++-- util/json.h

[ndctl PATCH 2/3] ndctl/list.c: simplify flags handling

2018-06-29 Thread Ross Zwisler
ce and use it everywhere. Signed-off-by: Ross Zwisler --- ndctl/list.c | 54 +++--- util/filter.h | 1 - 2 files changed, 27 insertions(+), 28 deletions(-) diff --git a/ndctl/list.c b/ndctl/list.c index 030d73f..32f679b 100644 --- a/ndctl/list.c +

[ndctl PATCH 1/3] ndctl: simplify JSON print flag handling

2018-06-29 Thread Ross Zwisler
varied. Instead, just pass in the necessary flag when calling json_object_to_json_string_ext(), removing the local variables and the extra argument to util_display_json_array(). Signed-off-by: Ross Zwisler --- daxctl/list.c| 5 ++--- ndctl/bus.c | 3 +-- ndctl/dimm.c

Re: [PATCH v2 2/2] ext4: handle layout changes to pinned DAX mappings

2018-06-29 Thread Ross Zwisler
On Fri, Jun 29, 2018 at 02:02:23PM +0200, Lukas Czerner wrote: > On Wed, Jun 27, 2018 at 03:22:52PM -0600, Ross Zwisler wrote: > > Follow the lead of xfs_break_dax_layouts() and add synchronization between > > operations in ext4 which remove blocks from an inode (hole punch, truncat

Re: [PATCH v3 1/3] pmem: only set QUEUE_FLAG_DAX for fsdax mode

2018-06-28 Thread Ross Zwisler
On Thu, Jun 28, 2018 at 05:42:34PM +, Kani, Toshi wrote: > On Tue, 2018-06-26 at 16:04 -0600, Ross Zwisler wrote: > > On Tue, Jun 26, 2018 at 02:51:52PM -0700, Dan Williams wrote: > > > On Tue, Jun 26, 2018 at 2:31 PM, Kani, Toshi wrote: > > > > On Tue, 2018-06-2

Re: [ndctl PATCH] Documentation: add a newline in namespace Theory of Operations

2018-06-27 Thread Ross Zwisler
On Wed, Jun 27, 2018 at 04:15:43PM -0600, Vishal Verma wrote: > The first bullet in the modes description was merged in with the > previous paragraph in the online version of the man pages. Fix by adding > a newline before the bulleted list. > > Reported-by: Ross Zwisler > Sig

[PATCH v2 1/2] dax: dax_layout_busy_page() warn on !exceptional

2018-06-27 Thread Ross Zwisler
-by: Ross Zwisler Reviewed-by: Jan Kara --- fs/dax.c | 10 +- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/fs/dax.c b/fs/dax.c index 641192808bb6..897b51e41d8f 100644 --- a/fs/dax.c +++ b/fs/dax.c @@ -566,7 +566,8 @@ struct page *dax_layout_busy_page(struct address_space

[PATCH v2 2/2] ext4: handle layout changes to pinned DAX mappings

2018-06-27 Thread Ross Zwisler
Follow the lead of xfs_break_dax_layouts() and add synchronization between operations in ext4 which remove blocks from an inode (hole punch, truncate down, etc.) and pages which are pinned due to DAX DMA operations. Signed-off-by: Ross Zwisler Reviewed-by: Jan Kara --- fs/ext4/ext4.h | 1

[PATCH v2 0/2] ext4: fix DAX dma vs truncate/hole-punch

2018-06-27 Thread Ross Zwisler
sted by Jan. * Removed the ext4_break_layouts() call in ext4_truncate_failed_write() and added a comment instead. (Jan) * Added reviewed-by tags from Jan. Ross Zwisler (2): dax: dax_layout_busy_page() warn on !exceptional ext4: handle layout changes to pinned DAX mappings fs/dax.c

Re: [PATCH 2/2] ext4: handle layout changes to pinned DAX mappings

2018-06-27 Thread Ross Zwisler
On Fri, Jun 22, 2018 at 10:19:15AM +0200, Jan Kara wrote: > On Wed 20-06-18 16:15:03, Ross Zwisler wrote: > > Follow the lead of xfs_break_dax_layouts() and add synchronization between > > operations in ext4 which remove blocks from an inode (hole punch, truncate > > down,

[PATCH v5 2/3] dax: bdev_dax_supported() check for QUEUE_FLAG_DAX

2018-06-26 Thread Ross Zwisler
a filesystem on that device mount with the DAX option. Signed-off-by: Ross Zwisler Suggested-by: Mike Snitzer Fixes: commit 545ed20e6df6 ("dm: add infrastructure for DAX support") Cc: sta...@vger.kernel.org --- drivers/dax/super.c | 8 1 file changed, 8 insertions(+) diff --git a/d

[PATCH v5 0/3] Fix DM DAX handling

2018-06-26 Thread Ross Zwisler
ramdisk which can hold a filesystem mounted with the -o dax mount option. All I/O to this filesystem will fail. --- Changes since v4: * No code changes. * Updated the changelogs for patches 1 and 3. * Removed the Cc: stable from patch 1. * Added a Fixes: tag to patch 2. Ross Zwisler

[PATCH v5 1/3] pmem: only set QUEUE_FLAG_DAX for fsdax mode

2018-06-26 Thread Ross Zwisler
re 'struct page' by default for filesystem dax". Signed-off-by: Ross Zwisler Suggested-by: Mike Snitzer --- drivers/nvdimm/pmem.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/nvdimm/pmem.c b/drivers/nvdimm/pmem.c index 68940356cad3..8b1fd7f1a224 100644 --- a/d

[PATCH v5 3/3] dm: prevent DAX mounts if not supported

2018-06-26 Thread Ross Zwisler
in dm_table_set_restrictions(). Now that bdev_dax_supported() explicitly checks for QUEUE_FLAG_DAX, this will ensure that filesystems built upon DM devices will only be able to mount with DAX if all underlying devices also support DAX. Signed-off-by: Ross Zwisler Fixes: commit 545ed20e6df6 ("dm: add infrastru

Re: [PATCH v3 1/3] pmem: only set QUEUE_FLAG_DAX for fsdax mode

2018-06-26 Thread Ross Zwisler
On Tue, Jun 26, 2018 at 02:51:52PM -0700, Dan Williams wrote: > On Tue, Jun 26, 2018 at 2:31 PM, Kani, Toshi wrote: > > On Tue, 2018-06-26 at 14:28 -0700, Dan Williams wrote: > >> On Tue, Jun 26, 2018 at 2:23 PM, Kani, Toshi wrote: > >> > On Tue, 2018-06-26 at 14:02 -0700, Dan Williams wrote: >

Re: [PATCH v3 1/3] pmem: only set QUEUE_FLAG_DAX for fsdax mode

2018-06-26 Thread Ross Zwisler
On Tue, Jun 26, 2018 at 12:07:40PM -0700, Dan Williams wrote: > On Tue, Jun 26, 2018 at 11:58 AM, Mike Snitzer wrote: > > On Tue, Jun 26 2018 at 2:52pm -0400, > > Dan Williams wrote: > > > >> On Tue, Jun 26, 2018 at 10:59 AM, Ross Zwisler > >> wrote:

Re: [PATCH v3 1/3] pmem: only set QUEUE_FLAG_DAX for fsdax mode

2018-06-26 Thread Ross Zwisler
On Tue, Jun 26, 2018 at 02:58:30PM -0400, Mike Snitzer wrote: > On Tue, Jun 26 2018 at 2:52pm -0400, > Dan Williams wrote: > > > On Tue, Jun 26, 2018 at 10:59 AM, Ross Zwisler > > wrote: > > > QUEUE_FLAG_DAX is an indication that a given block device supports &

[PATCH v4 3/3] dm: prevent DAX mounts if not supported

2018-06-26 Thread Ross Zwisler
be able to mount with DAX if all underlying devices also support DAX. Signed-off-by: Ross Zwisler Fixes: commit 545ed20e6df6 ("dm: add infrastructure for DAX support") Cc: sta...@vger.kernel.org --- Changes in v4: * Set/clear QUEUE_FLAG_DAX in dm_table_set_restrictions(). (Mike) --

[PATCH v3 3/3] dm: prevent DAX mounts if not supported

2018-06-26 Thread Ross Zwisler
be able to mount with DAX if all underlying devices also support DAX. Signed-off-by: Ross Zwisler Fixes: commit 545ed20e6df6 ("dm: add infrastructure for DAX support") Cc: sta...@vger.kernel.org --- drivers/md/dm-ioctl.c | 5 + drivers/md/dm-table.c | 7 +++

[PATCH v3 0/3] Fix DM DAX handling

2018-06-26 Thread Ross Zwisler
of DM_TYPE_DAX_BIO_BASED reworks. (Mike) * Dropped the first 2 prep patches of v2 since they were merged for v4.18-rc1. (Thanks, Darrick!) --- Mike, can you take this series through your tree? Personally I think this should be treated as a bug fix and merged in the v4.18-rc* series. Ross Zwisler (3

[PATCH v3 2/3] dax: bdev_dax_supported() check for QUEUE_FLAG_DAX

2018-06-26 Thread Ross Zwisler
a filesystem on that device mount with the DAX option. Signed-off-by: Ross Zwisler Suggested-by: Mike Snitzer Cc: sta...@vger.kernel.org --- drivers/dax/super.c | 8 1 file changed, 8 insertions(+) diff --git a/drivers/dax/super.c b/drivers/dax/super.c index 903d9c473749..45276abf03aa 100644

[PATCH v3 1/3] pmem: only set QUEUE_FLAG_DAX for fsdax mode

2018-06-26 Thread Ross Zwisler
QUEUE_FLAG_DAX is an indication that a given block device supports filesystem DAX and should not be set for PMEM namespaces which are in "raw" or "sector" modes. These namespaces lack struct page and are prevented from participating in filesystem DAX. Signed-off-by: Ros

Re: [PATCH v2 4/7] dm: prevent DAX mounts if not supported

2018-06-25 Thread Ross Zwisler
On Wed, Jun 20, 2018 at 11:17:49AM -0400, Mike Snitzer wrote: > On Mon, Jun 04 2018 at 7:15pm -0400, > Ross Zwisler wrote: > > > On Fri, Jun 01, 2018 at 05:55:13PM -0400, Mike Snitzer wrote: > > > On Tue, May 29 2018 at 3:51pm -0400, > > > Ross Zwisler wrote:

Re: [fstests PATCH 1/2] src/: fix up mmap() error checking

2018-06-22 Thread Ross Zwisler
On Fri, Jun 22, 2018 at 10:28:38AM +0800, Eryu Guan wrote: > On Wed, Jun 20, 2018 at 04:51:46PM -0600, Ross Zwisler wrote: > > I noticed that in some of my C tests in src/ I was incorrectly checking for > > mmap() failure by looking for NULL instead of MAP_FAILED. Fix those and &g

Re: [fstests PATCH 2/2] generic/999: test DAX DMA vs truncate/hole-punch

2018-06-21 Thread Ross Zwisler
On Thu, Jun 21, 2018 at 12:18:42PM +1000, Dave Chinner wrote: > On Wed, Jun 20, 2018 at 04:51:47PM -0600, Ross Zwisler wrote: <> > > +rm -f $seqres.full > > + > > +# Modify as appropriate. > > +_supported_fs generic > > +_supported_os Linux > &

[fstests PATCH 2/2] generic/999: test DAX DMA vs truncate/hole-punch

2018-06-20 Thread Ross Zwisler
1); If you change this to a WARN_ON() instead, you can see that each of the four paths being exercised in this test hits that condition many times in the one second that the subtest is being run. Signed-off-by: Ross Zwisler --- .gitignore | 1 + src/Makefile |

[PATCH 1/2] dax: dax_layout_busy_page() warn on !exceptional

2018-06-20 Thread Ross Zwisler
-by: Ross Zwisler --- fs/dax.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/fs/dax.c b/fs/dax.c index 641192808bb6..4a5e31f8a2d4 100644 --- a/fs/dax.c +++ b/fs/dax.c @@ -566,7 +566,7 @@ struct page *dax_layout_busy_page(struct address_space *mapping

[PATCH 2/2] ext4: handle layout changes to pinned DAX mappings

2018-06-20 Thread Ross Zwisler
Follow the lead of xfs_break_dax_layouts() and add synchronization between operations in ext4 which remove blocks from an inode (hole punch, truncate down, etc.) and pages which are pinned due to DAX DMA operations. Signed-off-by: Ross Zwisler --- fs/ext4/ext4.h | 1 + fs/ext4/extents.c

[PATCH 0/2] ext4: fix DAX dma vs truncate/hole-punch

2018-06-20 Thread Ross Zwisler
times in my test setup with the xfstest. I'll post this test shortly. With these patches applied, I've still seen occasional hits of the above WARN_ON_ONCE(), which tells me that we still have some work to do. I'll continue looking at these more rare hits while we review this set. Ross Zwisler

Re: [PATCH] tools/testing/nvdimm: advertise a write cache for nfit_test

2018-06-18 Thread Ross Zwisler
ribed in the ACPI NFIT. The > nfit_test unit tests expected a write cache to be present, so change the > nfit test namespaces to only advertise a persistence domain limited to > the memory controller. This allows the kernel to show a write_cache > attribute, and the test behaviour remains unch

Re: [fstests PATCH] generic/223: skip when using DAX

2018-06-13 Thread Ross Zwisler
On Wed, Jun 13, 2018 at 03:25:58PM -0700, Darrick J. Wong wrote: > On Wed, Jun 13, 2018 at 03:07:42PM -0600, Ross Zwisler wrote: > > As of these upstream kernel commits: > > > > commit 6e2608dfd934 ("xfs, dax: introduce xfs_dax_aops") > > commit 5f0663bb4a64

Re: [PATCH v11 4/7] mm, fs, dax: handle layout changes to pinned dax mappings

2018-06-12 Thread Ross Zwisler
approach assumes that the page > pinning is transient, if that assumption is violated the system would > have likely hung from the uncompleted I/O. > > Cc: Jeff Moyer > Cc: Dave Chinner > Cc: Matthew Wilcox > Cc: Alexander Viro > Cc: "Darrick J. Wong" > Cc: R

Re: [PATCH v4 11/12] mm, memory_failure: Teach memory_failure() about dev_pagemap pages

2018-06-12 Thread Ross Zwisler
cleared. > > Cc: Jan Kara > Cc: Christoph Hellwig > Cc: Jérôme Glisse > Cc: Matthew Wilcox > Cc: Naoya Horiguchi > Cc: Ross Zwisler > Signed-off-by: Dan Williams > --- <> > +static int memory_failure_dev_pagemap(unsigned long pfn, int flags, &

Re: [PATCH v4 10/12] filesystem-dax: Introduce dax_lock_page()

2018-06-12 Thread Ross Zwisler
On Fri, Jun 08, 2018 at 04:51:14PM -0700, Dan Williams wrote: > In preparation for implementing support for memory poison (media error) > handling via dax mappings, implement a lock_page() equivalent. Poison > error handling requires rmap and needs guarantees that the page->mapping > association

Re: [PATCH v4 10/12] filesystem-dax: Introduce dax_lock_page()

2018-06-12 Thread Ross Zwisler
On Mon, Jun 11, 2018 at 05:41:46PM +0200, Jan Kara wrote: > On Fri 08-06-18 16:51:14, Dan Williams wrote: > > In preparation for implementing support for memory poison (media error) > > handling via dax mappings, implement a lock_page() equivalent. Poison > > error handling requires rmap and needs

Re: [qemu PATCH 1/5] gitignore: ignore generated qapi job files

2018-06-08 Thread Ross Zwisler
On Fri, Jun 08, 2018 at 09:59:00AM -0500, Eric Blake wrote: > On 06/07/2018 05:31 PM, Ross Zwisler wrote: > > With a fully built QEMU I currently see the following with "git status": > > > >Untracked files: > > (use "git add ..." to inclu

Re: [Qemu-devel] [qemu PATCH 2/5] acpi: "make check" should fail on asl mismatch

2018-06-08 Thread Ross Zwisler
On Fri, Jun 08, 2018 at 07:17:51AM +0200, Thomas Huth wrote: > On 08.06.2018 01:09, Michael S. Tsirkin wrote: > > On Thu, Jun 07, 2018 at 04:31:08PM -0600, Ross Zwisler wrote: > >> Currently if "make check" detects a mismatch in the ASL generated during >

[qemu PATCH 4/5] machine: fix some misspelled words

2018-06-07 Thread Ross Zwisler
Normally this might not be worth fixing, but several of these are strings which are displayed to users. Signed-off-by: Ross Zwisler --- hw/core/machine.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/core/machine.c b/hw/core/machine.c index 617e5f8d75..a21269fa39

[qemu PATCH 1/5] gitignore: ignore generated qapi job files

2018-06-07 Thread Ross Zwisler
s-job.h qapi/qapi-types-job.c qapi/qapi-types-job.h qapi/qapi-visit-job.c qapi/qapi-visit-job.h These are all generated files. Ignore them. Signed-off-by: Ross Zwisler Cc: Kevin Wolf Cc: Eric Blake Fixes: commit bf42508f24ee ("job: Introduce qapi/job.json&q

[qemu PATCH 2/5] acpi: "make check" should fail on asl mismatch

2018-06-07 Thread Ross Zwisler
DT.dimmpxm]. but the testing still exits with good shell status. This is wrong, and makes bisecting such a failure difficult. Signed-off-by: Ross Zwisler --- tests/bios-tables-test.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/bios-tables-test.c b/tests/bios-tables-test.c index 256d463cb8..

[qemu PATCH 3/5] hw/i386: Update SSDT table used by "make check"

2018-06-07 Thread Ross Zwisler
reflects this name change. Signed-off-by: Ross Zwisler Cc: Peter Maydell Cc: Cornelia Huck Cc: Thomas Huth Cc: Eduardo Habkost Fixes: commit aa78a16d8645 ("hw/i386: Rename 2.13 machine types to 3.0") --- tests/acpi-test-data/q35/SSDT.dimmpxm | Bin 685 -> 685 bytes 1 file changed

Re: [PATCH v3 2/4] libnvdimm: unconditionally deep flush on *sync

2018-06-06 Thread Ross Zwisler
On Wed, Jun 06, 2018 at 10:57:59AM -0700, Dan Williams wrote: > On Wed, Jun 6, 2018 at 9:45 AM, Ross Zwisler > wrote: > > Prior to this commit we would only do a "deep flush" (have nvdimm_flush() > > write to each of the flush hints for a region) in response to

Re: [PATCH v2 5/7] dm: remove DM_TYPE_DAX_BIO_BASED dm_queue_mode

2018-06-06 Thread Ross Zwisler
On Mon, Jun 04, 2018 at 08:46:28PM -0400, Mike Snitzer wrote: > On Mon, Jun 04 2018 at 7:24pm -0400, > Ross Zwisler wrote: > > > On Fri, Jun 01, 2018 at 06:04:43PM -0400, Mike Snitzer wrote: > > > On Tue, May 29 2018 at 3:51pm -0400, &

Re: [qemu PATCH v4 3/4] nvdimm, acpi: support NFIT platform capabilities

2018-06-06 Thread Ross Zwisler
On Wed, Jun 06, 2018 at 11:00:33AM -0600, Ross Zwisler wrote: > On Wed, Jun 06, 2018 at 10:50:51AM -0600, Ross Zwisler wrote: > > On Tue, Jun 05, 2018 at 03:21:30PM -0700, Dan Williams wrote: > > > On Tue, Jun 5, 2018 at 3:07 PM, Ross Zwisler > > > wrote: > >

Re: [qemu PATCH v4 3/4] nvdimm, acpi: support NFIT platform capabilities

2018-06-06 Thread Ross Zwisler
On Wed, Jun 06, 2018 at 10:50:51AM -0600, Ross Zwisler wrote: > On Tue, Jun 05, 2018 at 03:21:30PM -0700, Dan Williams wrote: > > On Tue, Jun 5, 2018 at 3:07 PM, Ross Zwisler > > wrote: > > > On Tue, Jun 05, 2018 at 09:37:25PM +0300, Michael S. Tsirkin wrote: > > &g

Re: [qemu PATCH v4 3/4] nvdimm, acpi: support NFIT platform capabilities

2018-06-06 Thread Ross Zwisler
On Tue, Jun 05, 2018 at 03:21:30PM -0700, Dan Williams wrote: > On Tue, Jun 5, 2018 at 3:07 PM, Ross Zwisler > wrote: > > On Tue, Jun 05, 2018 at 09:37:25PM +0300, Michael S. Tsirkin wrote: > >> On Tue, Jun 05, 2018 at 11:15:00AM -0700, Dan Williams wrote: > >> &g

[PATCH v3 1/4] pmem, libnvdimm: complete REQ_FLUSH => REQ_PREFLUSH

2018-06-06 Thread Ross Zwisler
Complete the move from REQ_FLUSH to REQ_PREFLUSH that apparently started way back in v4.8. Signed-off-by: Ross Zwisler --- drivers/nvdimm/pmem.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/nvdimm/pmem.c b/drivers/nvdimm/pmem.c index 9d714926ecf5

[PATCH v3 4/4] libnvdimm: don't flush power-fail protected CPU caches

2018-06-06 Thread Ross Zwisler
pace. See libndctl's ndctl_namespace_write_cache_is_enabled(), ndctl_namespace_enable_write_cache() and ndctl_namespace_disable_write_cache() functions. Signed-off-by: Ross Zwisler Fixes: 5fdf8e5ba566 ("libnvdimm: re-enable deep flush for pmem devices via fsync()") --- drivers/nvdimm/region_de

[PATCH v3 2/4] libnvdimm: unconditionally deep flush on *sync

2018-06-06 Thread Ross Zwisler
the *sync deep flush always happen, regardless of the write cache setting of a namespace. The DAX CPU cache flushing will still be controlled the write_cache setting of the namespace. Signed-off-by: Ross Zwisler Suggested-by: Dan Williams --- drivers/nvdimm/pmem.c | 7 +++ 1 file changed

[PATCH v3 3/4] libnvdimm: use dax_write_cache* helpers

2018-06-06 Thread Ross Zwisler
Use dax_write_cache() and dax_write_cache_enabled() instead of open coding the bit operations. Signed-off-by: Ross Zwisler --- drivers/dax/super.c | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/drivers/dax/super.c b/drivers/dax/super.c index 2b2332b605e4

Re: [PATCH v2 3/3] libnvdimm: don't flush power-fail protected CPU caches

2018-06-06 Thread Ross Zwisler
On Tue, Jun 05, 2018 at 07:00:14PM -0700, Dan Williams wrote: > On Tue, Jun 5, 2018 at 4:58 PM, Ross Zwisler > wrote: > > This commit: > > > > 5fdf8e5ba566 ("libnvdimm: re-enable deep flush for pmem devices via > > fsync()") > > > > intended to

[PATCH v2 1/3] libnvdimm: unconditionally deep flush on *sync

2018-06-05 Thread Ross Zwisler
he write_cache setting as well as whether the platform supports flush-on-fail CPU caches. Signed-off-by: Ross Zwisler Suggested-by: Dan Williams --- drivers/nvdimm/pmem.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/nvdimm/pmem.c b/drivers/nvdimm/pmem.c index 9d7

[PATCH v2 3/3] libnvdimm: don't flush power-fail protected CPU caches

2018-06-05 Thread Ross Zwisler
he ability to skip flushing CPU caches on those power-fail protected CPU cache. Signed-off-by: Ross Zwisler Fixes: 5fdf8e5ba566 ("libnvdimm: re-enable deep flush for pmem devices via fsync()") --- drivers/dax/super.c | 14 +- drivers/nvdimm/pmem.c | 2 ++ include/linux/dax.h

[PATCH v2 2/3] libnvdimm: use dax_write_cache* helpers

2018-06-05 Thread Ross Zwisler
Use dax_write_cache() and dax_write_cache_enabled() instead of open coding the bit operations. Signed-off-by: Ross Zwisler --- drivers/dax/super.c | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/drivers/dax/super.c b/drivers/dax/super.c index 2b2332b605e4

Re: [qemu PATCH v4 3/4] nvdimm, acpi: support NFIT platform capabilities

2018-06-05 Thread Ross Zwisler
On Tue, Jun 05, 2018 at 09:37:25PM +0300, Michael S. Tsirkin wrote: > On Tue, Jun 05, 2018 at 11:15:00AM -0700, Dan Williams wrote: > > On Tue, Jun 5, 2018 at 9:42 AM, Ross Zwisler > > wrote: > > > On Tue, Jun 05, 2018 at 06:25:27PM +0300, Michael S. Tsirkin wrote: >

Re: [PATCH 2/2] libnvdimm: don't flush power-fail protected CPU caches

2018-06-05 Thread Ross Zwisler
On Tue, Jun 05, 2018 at 02:20:38PM -0700, Dan Williams wrote: > On Tue, Jun 5, 2018 at 1:58 PM, Ross Zwisler > wrote: > > This commit: > > > > 5fdf8e5ba566 ("libnvdimm: re-enable deep flush for pmem devices via > > fsync()") > > > > intended to

[PATCH 1/2] libnvdimm: use dax_write_cache* helpers

2018-06-05 Thread Ross Zwisler
Use dax_write_cache() and dax_write_cache_enabled() instead of open coding the bit operations. Signed-off-by: Ross Zwisler --- drivers/dax/super.c | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/drivers/dax/super.c b/drivers/dax/super.c index 2b2332b605e4

[PATCH 2/2] libnvdimm: don't flush power-fail protected CPU caches

2018-06-05 Thread Ross Zwisler
he ability to skip flushing CPU caches on those power-fail protected CPU cache. Signed-off-by: Ross Zwisler Fixes: 5fdf8e5ba566 ("libnvdimm: re-enable deep flush for pmem devices via fsync()") --- drivers/dax/super.c | 20 +++- drivers/nvdimm/pmem.c | 2 ++ includ

Re: [qemu PATCH v4 3/4] nvdimm, acpi: support NFIT platform capabilities

2018-06-05 Thread Ross Zwisler
On Tue, Jun 05, 2018 at 06:25:27PM +0300, Michael S. Tsirkin wrote: > On Mon, May 21, 2018 at 10:32:02AM -0600, Ross Zwisler wrote: > > Add a machine command line option to allow the user to control the Platform > > Capabilities Structure in the virtualized NFIT. This Platfo

Re: [PATCH v2 5/7] dm: remove DM_TYPE_DAX_BIO_BASED dm_queue_mode

2018-06-04 Thread Ross Zwisler
On Fri, Jun 01, 2018 at 06:04:43PM -0400, Mike Snitzer wrote: > On Tue, May 29 2018 at 3:51pm -0400, > Ross Zwisler wrote: > > > The DM_TYPE_DAX_BIO_BASED dm_queue_mode was introduced to prevent DM > > devices that could possibly support DAX from transitioning into DM de

Re: [PATCH v2 4/7] dm: prevent DAX mounts if not supported

2018-06-04 Thread Ross Zwisler
On Fri, Jun 01, 2018 at 05:55:13PM -0400, Mike Snitzer wrote: > On Tue, May 29 2018 at 3:51pm -0400, > Ross Zwisler wrote: > > > Currently the code in dm_dax_direct_access() only checks whether the target > > type has a direct_access() operation defined, not whether the

  1   2   3   4   5   6   7   8   >