Skip to contentSkip to conversation

io_uring work-around for S_IFREG anon inodes

GIT PULL Merged Jens Axboe 2 participants 2 messages Jun 30, 2025 – Jul 1, 2025 io_uring

lore
Share & tools
lore

Jens Axboe

author maintainer
#0 lore raw

Hi Linus,

Sending this one out early as the patch that broke io_uring is already in 6.15.4 stable, and I'd like to get the fix included for 6.15.5.

tldr is that now that anonymous inodes set S_IFREG, this breaks the io_uring read/write retries for short reads/writes. As things like timerfd and eventfd are anon inodes, applications that previously did:

unsigned long event_data[2];

io_uring_prep_read(sqe, evfd, event_data, sizeof(event_data), 0);

and just got a short read when 1 event was posted, will now wait for the full amount before posting a completion. This caused issues for the ghostty application, making it basically unusable due to excessive buffering.

Please pull!

The following changes since commit 178b8ff66ff827c41b4fa105e9aabb99a0b5c537:

io_uring/kbuf: flag partial buffer mappings (2025-06-26 12:17:48 -0600)

are available in the Git repository at:

git://git.kernel.dk/linux.git tags/io_uring-6.16-20250630

for you to fetch changes up to 6f11adcc6f36ffd8f33dbdf5f5ce073368975bc3:

io_uring: gate REQ_F_ISREG on !S_ANON_INODE as well (2025-06-29 16:52:34 -0600)

----------------------------------------------------------------
io_uring-6.16-20250630

----------------------------------------------------------------
Jens Axboe (1):
io_uring: gate REQ_F_ISREG on !S_ANON_INODE as well

 io_uring/io_uring.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
Signature · 1 line
Jens Axboe