]> git.baikalelectronics.ru Git - kernel.git/commit
io_uring: fix a memory leak of buffer group list on exit
authorJens Axboe <axboe@kernel.dk>
Thu, 26 May 2022 17:34:33 +0000 (11:34 -0600)
committerJens Axboe <axboe@kernel.dk>
Tue, 31 May 2022 08:50:06 +0000 (02:50 -0600)
commit59d82d0e0092369da0b9b5779b798b862cc1be84
tree48e100de76ae52bd15636ea49492ddaefe82f862
parentab8ef4c8db0aa8574a8d7a6e2ef5b3ccb63af3a9
io_uring: fix a memory leak of buffer group list on exit

If we use a buffer group ID that is large enough to require io_uring
to allocate it, then we don't correctly free it if the cleanup is
deferred to the ring exit. The explicit removal paths are fine.

Fixes: 788b05f6311b ("io_uring: get rid of hashed provided buffer groups")
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c