Re: [PATCH] mm: filemap: tighten dropbehind completion context check

From: Wenjie Qi

Date: Sat Aug 29 2026 - 08:13:58 EST


I kept the helper private to avoid an MM dependency on <linux/bio.h>.

After looking further at the mapped-folio case Matthew raised, I think the
better fix is to retain a dropbehind folio once it is mapped. A mapping
represents a competing cached user, and retaining it avoids the sleeping
unmap path, so filemap no longer needs a stricter context helper; the
existing in_task() guard remains. I will respin the patch on that basis.