Re: [PATCH 0/3] mm: introduce snapshot_page()

From: Luiz Capitulino
Date: Wed Jul 02 2025 - 13:39:41 EST


On 2025-07-02 02:40, Shivank Garg wrote:


On 6/26/2025 11:46 PM, Luiz Capitulino wrote:
Hi,

This series introduces snapshot_page(), a helper function that can be used
to create a snapshot of a struct page and its associated struct folio.

This function is intended to help callers with a consistent view of a
a folio while reducing the chance of encountering partially updated or
inconsistent state, such as during folio splitting which could lead to
crashes and BUG_ON()s being triggered.

We could consider adding a Reported-by: tag and a link to the syzbot report.

I believe this is the relevant one:
https://lore.kernel.org/all/67812fbd.050a0220.d0267.0030.GAE@xxxxxxxxxx

I'll add it, thanks for the review.