CVE-2026-74319: btrfs: zoned: fix deadlock waiting for ticket during data relocation
In the Linux kernel, the following vulnerability has been resolved:
btrfs: zoned: fix deadlock waiting for ticket during data relocation
When performing data relocation on a zoned filesystem, BTRFS can deadlock in handlereservetickets(). The relocation process is waiting on a space reservation ticket that can never be fulfilled, because the relocation itself is the operation responsible for freeing up that space.
Fix this by introducing a new flush state, BTRFSRESERVEFLUSHZONEDRELOCATION, specifically for data chunk allocation during zoned relocation. Like BTRFSRESERVEFLUSHFREESPACEINODE, this state uses priorityreclaimdataspace() instead of the normal flushing path, which avoids re-entering the relocation code and breaking the deadlock cycle.
In btrfsallocdatachunkondemand(), select this new flush state when the inode belongs to a data relocation root on a zoned filesystem.