On Fri 01-03-19 11:12:41, Matthew Wilcox wrote:
> The radix tree would rewind the index in an iterator to the lowest index
> of a multi-slot entry.  The XArray iterators instead leave the index
> unchanged, but I overlooked that when converting DAX from the radix tree
> to the XArray.  Adjust the index that we use for flushing to the start
> of the PMD range.
> 
> Fixes: c1901cd33cf4 "page cache: Convert find_get_entries_tag to XArray"
> Reported-by: Piotr Balcer <[email protected]>
> Tested-by: Dan Williams <[email protected]>
> Signed-off-by: Matthew Wilcox <[email protected]>
> ---
...
> @@ -917,8 +917,7 @@ static int dax_writeback_one(struct xa_state *xas, struct 
> dax_device *dax_dev,
>       xas_clear_mark(xas, PAGECACHE_TAG_DIRTY);
>       dax_wake_entry(xas, entry, false);
>  
> -     trace_dax_writeback_one(mapping->host, xas->xa_index,
> -                     size >> PAGE_SHIFT);
> +     trace_dax_writeback_one(mapping->host, xas->xa_index, count);

I think here should be 'index' as well, shouldn't it? Otherwise the tracing
data will be somewhat misleading... Besides this the patch looks good to me
now so feel free to add:

Reviewed-by: Jan Kara <[email protected]>

                                                                Honza
-- 
Jan Kara <[email protected]>
SUSE Labs, CR
_______________________________________________
Linux-nvdimm mailing list
[email protected]
https://lists.01.org/mailman/listinfo/linux-nvdimm

Reply via email to