Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
binder: add lockless binder_alloc_(set|get)_vma()
commit 0fa5334 upstream. Bring back the original lockless design in binder_alloc to determine whether the buffer setup has been completed by the ->mmap() handler. However, this time use smp_load_acquire() and smp_store_release() to wrap all the ordering in a single macro call. Also, add comments to make it evident that binder uses alloc->vma to determine when the binder_alloc has been fully initialized. In these scenarios acquiring the mmap_lock is not required. Fixes: a43cfc8 ("android: binder: stop saving a pointer to the VMA") Cc: Liam Howlett <[email protected]> Cc: Suren Baghdasaryan <[email protected]> Cc: [email protected] Signed-off-by: Carlos Llamas <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
- Loading branch information