Re: [PATCH v4, RESEND] fs/dax: check zero or empty entry before converting xarray entry
Andrew Morton <[email protected]> Thu, 30 Jul 2026 10:38:04 -0700
| Newsgroups | dev.linux.lists.nvdimm,org.kernel.vger.linux-fsdevel,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <[email protected]> |
On Thu, 30 Jul 2026 14:12:55 +0100 Seunguk Shin <[email protected]> wrote: > dax_associate_entry(), dax_disassociate_entry(), and dax_busy_page() > call dax_to_folio(entry) before checking whether entry is a zero or > empty xarray entry. > > That ordering is wrong because zero and empty entries are not folio > entries. Commit 98c183a4fccf ("fs/dax: don't disassociate zero page > entries") added guards in the associate and disassociate paths, but the > guards still come after dax_to_folio(entry), and dax_busy_page() still > has the same problem. Are there any known userspace-visible runtime effects of this? If so, please fully describe them in the changelog. If not, please also mention that. This is important information for deciding which kernel(s) need the patch. > Move the zero/empty checks before dax_to_folio(entry) in all three helpers. Thanks.