Details
-
Bug
-
Resolution: Fixed
-
Minor
-
None
-
3
-
9223372036854775807
Description
int cl_io_loop(const struct lu_env *env, struct cl_io *io) { int result = 0; int rc = 0; ... if (result == -EAGAIN && io->ci_ndelay) { io->ci_need_restart = 1; result = 0; } if (result == 0) result = io->ci_result; RETURN(result < 0 ? result : 0); } EXPORT_SYMBOL(cl_io_loop);
ssize_t generic_file_read_iter(struct kiocb *iocb, struct iov_iter *iter) { ... if (iocb->ki_flags & IOCB_NOWAIT) { if (filemap_range_has_page(mapping, iocb->ki_pos, iocb->ki_pos + count - 1)) return -EAGAIN; ...
We should handle FLR mirror retry and io_uring IOCB_NOWAIT differently.
In the current code, it will restart the I/O engine loop when get -EAGAIN return code.
When io_uring with IOCB_NOWAIT flags and found there are page cache in the I/O range, we should return the -EAGAIN to the caller immediately.
Otherwise, it will Stuck in an endless loop。
Attachments
Issue Links
- is related to
-
LU-15994 Fio io_uring failed with error=interrupted system call on Ubuntu 2204
- Resolved