[PATCH] fs/dax: Remove redundant deferred list initialization

From: Kaitao Cheng

Date: Thu Sep 03 2026 - 01:02:50 EST


From: Kaitao Cheng <chengkaitao@xxxxxxxxxx>

prep_compound_page() calls prep_compound_head(), which initializes
folio->_deferred_list for compound folios with an order greater than one.
Therefore, dax_folio_init() initializes the list twice for large DAX
folios.

Remove the redundant initialization from dax_folio_init(). This leaves
the behavior unchanged and keeps compound folio initialization
centralized in prep_compound_head().

Signed-off-by: Kaitao Cheng <chengkaitao@xxxxxxxxxx>
---
fs/dax.c | 2 --
1 file changed, 2 deletions(-)

diff --git a/fs/dax.c b/fs/dax.c
index 6ba50142eeb2..dad4efea7964 100644
--- a/fs/dax.c
+++ b/fs/dax.c
@@ -469,8 +469,6 @@ static void dax_folio_init(void *entry)

if (order > 0) {
prep_compound_page(&folio->page, order);
- if (order > 1)
- INIT_LIST_HEAD(&folio->_deferred_list);
WARN_ON_ONCE(folio_ref_count(folio));
}
}
--
2.50.1 (Apple Git-155)