summaryrefslogtreecommitdiff
path: root/scripts/check-git
diff options
context:
space:
mode:
authorChris Mason <mason@kernel.org>2026-11-12 16:46:17 -0500
committerCarlos Maiolino <cem@kernel.org>2026-11-16 11:45:49 +0100
commit44e555acd77a839110f3b1e02a75f9165baaaeec (patch)
tree693223bb95b3c5b8a1c0aec13f405f9f065a20bb /scripts/check-git
parent03cbbd80a3e7070e8ab63996a94a7815722c2578 (diff)
xfs: don't enable DAX on zoned inodes
A store through a shared mapping can dereference a NULL pointer if the file is zoned and has S_DAX. The zoned code does not support DAX, but XFS doesn't check for this: with dax=always or FS_XFLAG_DAX, an inode gets S_DAX if its device does DAX, and an internal zoned section on pmem does. The write fault then takes the zoned path: xfs_filemap_fault() xfs_write_fault() xfs_write_fault_zoned() page_folio(vmf->page) /* NULL in a DAX fault */ ftruncate() crashes in a similar way, in xfs_reflink_end_cow(). The fix used here is to never set S_DAX on a zoned inode, and to refuse to change the realtime flag of an S_DAX inode on a zoned file system. Zoned files now use the page cache with dax=always or FS_XFLAG_DAX. A file whose realtime flag is cleared stays without DAX until its inode is evicted. Fixes: be458049ffe3 ("xfs: enable the zoned RT device feature") Signed-off-by: Chris Mason <mason@kernel.org> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Carlos Maiolino <cem@kernel.org>
Diffstat (limited to 'scripts/check-git')
0 files changed, 0 insertions, 0 deletions