]> git.hungrycats.org Git - linux/commit
io_uring/rsrc: improve regbuf iov validation
authorPavel Begunkov <asml.silence@gmail.com>
Tue, 25 Aug 2026 19:47:43 +0000 (15:47 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 2 Sep 2026 12:31:47 +0000 (14:31 +0200)
commit0bcec5dda029ce9574260089a83aa12e992a0dff
tree85ef72ceb9aeaee221cacd018279f40b707e692a
parente973a371d35a2ef6ebab5f5a569c7af8c67eff3d
io_uring/rsrc: improve regbuf iov validation

[ Upstream commit 2e02f9efdbc6c73544e315b7eb85e55a59776b6f ]

Deduplicate io_buffer_validate() calls by moving the checks into
io_sqe_buffer_register(). Now we also don't need special handling in
io_buffer_validate() passing through buffer removal requests. I also
was using it as a cleanup before some other changes.

Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Stable-dep-of: cd305ee3633a ("io_uring: defer eventfd signaling when queued from a wakeup handler")
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
io_uring/rsrc.c