Searched hist:b78beea0 (Results 1 – 1 of 1) sorted by relevance
/openbmc/linux/lib/ |
H A D | sbitmap.c | b78beea0 Sun Nov 22 09:35:45 CST 2020 Pavel Begunkov <asml.silence@gmail.com> sbitmap: optimise sbitmap_deferred_clear()
Because of spinlocks and atomics sbitmap_deferred_clear() have to reload &sb->map[index] on each access even though the map address won't change. Pass in sbitmap_word instead of {sb, index}, so it's cached in a variable. It also improves code generation of sbitmap_find_bit_in_index().
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com> Reviewed-by: John Garry <john.garry@huawei.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
|