Skip to contentSkip to conversation

FAILED: patch "[PATCH] fs/dax.c: fix inefficiency in dax_writeback_mapping_range()" failed to apply to 4.9-stable tree

PATCH [email protected] 1 participant 1 message Jun 26, 2017

Subsystems (3)
lore
Share & tools
lore

[email protected]

author maintainer
#0 lore raw

The patch below does not apply to the 4.9-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.

thanks,

greg k-h

------------------ original commit in Linus's tree ------------------

Quoted 1 line

From 1eb643d02b21412e603b42cdd96010a2ac31c05f Mon Sep 17 00:00:00 2001

From: Jan Kara <[email protected]>
Date: Fri, 23 Jun 2017 15:08:46 -0700
Subject: [PATCH] fs/dax.c: fix inefficiency in dax_writeback_mapping_range()

dax_writeback_mapping_range() fails to update iteration index when searching radix tree for entries needing cache flushing. Thus each pagevec worth of entries is searched starting from the start which is inefficient and prone to livelocks. Update index properly.

fs/dax.c +1 -0
index 2a6889b3585f..9187f3b07f3e 100644
@@ -859,6 +859,7 @@ int dax_writeback_mapping_range(struct address_space *mapping,
 			if (ret < 0)
 				goto out;
 		}
+		start_index = indices[pvec.nr - 1] + 1;
 	}
 out:
 	put_dax(dax_dev);