Skip to contentSkip to conversation

Revert "io_uring/rw: drop -EOPNOTSUPP check in __io_complete_rw_common()"

PATCH New Jens Axboe 1 participant 1 message Oct 13, 2025 io_uring

lore
Share & tools
lore

Jens Axboe

author maintainer
#0 lore raw

PATCH 1/1 Revert "io_uring/rw: drop -EOPNOTSUPP check in __io_complete_rw_common()"

This reverts commit 90bfb28d5fa8127a113a140c9791ea0b40ab156a.

Kevin reports that this commit causes an issue for him with LVM snapshots, most likely because of turning off NOWAIT support while a snapshot is being created. This makes -EOPNOTSUPP bubble back through the completion handler, where io_uring read/write handling should just retry it.

Reinstate the previous check removed by the referenced commit.

Fixes 90bfb28d5fa8 ("io_uring/rw: drop -EOPNOTSUPP check in __io_complete_rw_common()")

---

io_uring/rw.c +1 -1
index 08882648d569..a0f9d2021e3f 100644
@@ -542,7 +542,7 @@ static void __io_complete_rw_common(struct io_kiocb *req, long res)
 {
 	if (res == req->cqe.res)
 		return;
-	if (res == -EAGAIN && io_rw_should_reissue(req)) {
+	if ((res == -EOPNOTSUPP || res == -EAGAIN) && io_rw_should_reissue(req)) {
 		req->flags |= REQ_F_REISSUE | REQ_F_BL_NO_RECYCLE;
 	} else {
 		req_set_fail(req);
Signature · 1 line
Jens Axboe