Commit a880c450 authored by Carlos Llamas's avatar Carlos Llamas
Browse files

UPSTREAM: binder: do unlocked work in binder_alloc_new_buf()



Extract non-critical sections from binder_alloc_new_buf_locked() that
don't require holding the alloc->mutex. While we are here, consolidate
the checks for size overflow and zero-sized padding into a separate
sanitized_size() helper function.

Also add a few touchups to follow the coding guidelines.

Signed-off-by: default avatarCarlos Llamas <cmllamas@google.com>
Reviewed-by: default avatarAlice Ryhl <aliceryhl@google.com>
Link: https://lore.kernel.org/r/20231201172212.1813387-12-cmllamas@google.com


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>

Bug: 254650075
(cherry picked from commit 377e1684)
Change-Id: I8fc18c06563ad2c26536633034fb3e94b0aaf510
Signed-off-by: default avatarCarlos Llamas <cmllamas@google.com>
parent e5fae62f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment