Re: [BUG] Data race between xfs_file_release and xfs_bmap_del_extent_delay about i_delayed_blks

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, May 12, 2025 at 12:01:54PM +0800, cen zhang wrote:
> I would like to report a data race bug detected in
> the Btrfs filesystem on Linux kernel 6.14-rc4.

xfs?

> The issue was discovered by our tools,

As in KCSAN?

> Reader (fs/xfs/xfs_file.c):
> xfs_file_release  {
> ……
>         xfs_iflags_clear(ip, XFS_EOFBLOCKS_RELEASED);
>         if (ip->i_delayed_blks > 0)
>             filemap_flush(inode->i_mapping);
> ……
> }

And this should make it very clear that the race does not matter.
bu we should indeed throw in a data_race() and a comment to make that
clear.  I'll take care of that.





[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux