Date: Mon, 7 Jul 2025 17:52:56 GMT From: Konstantin Belousov <kib@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: 0c38e3dbbf6e - main - aio: if there is at least one aio thread, hide an error from aio_init_aioinfo() Message-ID: <202507071752.567HquuM036993@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=0c38e3dbbf6eaa2755d34189149c9140cacd4bb1 commit 0c38e3dbbf6eaa2755d34189149c9140cacd4bb1 Author: Konstantin Belousov <kib@FreeBSD.org> AuthorDate: 2025-07-07 14:35:11 +0000 Commit: Konstantin Belousov <kib@FreeBSD.org> CommitDate: 2025-07-07 17:52:20 +0000 aio: if there is at least one aio thread, hide an error from aio_init_aioinfo() Noted and reviewed by: jhb Fixes: 4685fa8e4bef169e6a1ceaf07f149232326de805 Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D51191 --- sys/kern/vfs_aio.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/sys/kern/vfs_aio.c b/sys/kern/vfs_aio.c index 66ea50eee77b..02973146068d 100644 --- a/sys/kern/vfs_aio.c +++ b/sys/kern/vfs_aio.c @@ -455,8 +455,15 @@ aio_init_aioinfo(struct proc *p) error = 0; while (num_aio_procs < MIN(target_aio_procs, max_aio_procs)) { error = aio_newproc(NULL); - if (error != 0) + if (error != 0) { + /* + * At least one worker is enough to have AIO + * functional. Clear error in that case. + */ + if (num_aio_procs > 0) + error = 0; break; + } } return (error); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202507071752.567HquuM036993>