aboutsummaryrefslogtreecommitdiff
path: root/lib/test-string_helpers.c
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2023-11-28 11:17:25 -0700
committerJens Axboe <axboe@kernel.dk>2023-11-28 11:45:02 -0700
commitb10b73c102a2eab91e1cd62a03d6446f1dfecc64 (patch)
tree66ddc4f45f3dd648d900a7cd0a169b8f3b969ae0 /lib/test-string_helpers.c
parentc392cbecd8eca4c53f2bf508731257d9d0a21c2d (diff)
io_uring/kbuf: recycle freed mapped buffer ring entries
Right now we stash any potentially mmap'ed provided ring buffer range for freeing at release time, regardless of when they get unregistered. Since we're keeping track of these ranges anyway, keep track of their registration state as well, and use that to recycle ranges when appropriate rather than always allocate new ones. The lookup is a basic scan of entries, checking for the best matching free entry. Fixes: c392cbecd8ec ("io_uring/kbuf: defer release of mapped buffer rings") Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'lib/test-string_helpers.c')
0 files changed, 0 insertions, 0 deletions