From: Kentaro Makita Date: Sat, 26 Jul 2008 02:44:40 +0000 (-0700) Subject: vfs: add cond_resched_lock while scanning dentry LRU lists X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=f3c6ba986ab4527b6dfacf9f3b9e40f72466a8b2;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git vfs: add cond_resched_lock while scanning dentry LRU lists Add cond_resched_lock(&dcache_lock) while scanning LRU lists on superblocks in __shrink_dcache_sb() Signed-off-by: Kentaro Makita Cc: Al Viro Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/fs/dcache.c b/fs/dcache.c index 3818d6ab76ca..f2584d22cb45 100644 --- a/fs/dcache.c +++ b/fs/dcache.c @@ -487,6 +487,7 @@ restart: if (!cnt) break; } + cond_resched_lock(&dcache_lock); } } while (!list_empty(&tmp)) {