binder: eliminate use of vmalloc space for binder buffers
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v3 Latest7 patches 8 repliesIn review
- v27 patches 2 repliesSuperseded
- v17 patches 3 repliesSuperseded
Patches in v3 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/7 | binder: create userspace-to-binder-buffer copy functiondrivers/ drivers/ drivers/ | +143 | 6 replies | |
| 2/7 | binder: add functions to copy to/from binder buffersdrivers/ drivers/ drivers/ +1 more | +147 | 0 replies | |
| 3/7 | binder: add function to copy binder object from bufferdrivers/ | +58 | 0 replies | |
| 4/7 | binder: avoid kernel vm_area for buffer fixupsdrivers/ | +97 | 0 replies | |
| 5/7 | binder: remove kernel vm_area for buffer spacedrivers/ | +2 | 0 replies | |
| 6/7 | binder: remove user_buffer_offsetdrivers/ drivers/ drivers/ | +13 | 0 replies | |
| 7/7 | binder: use userspace pointer as base of buffer spacedrivers/ drivers/ drivers/ +2 more | +118 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v3 yet.
Cover letter [PATCH v3 0/7] binder: eliminate use of vmalloc space for binder buffers
Binder buffers have always been mapped into kernel space via map_kernel_range_noflush() to allow the binder driver to modify the buffer before posting to userspace for processing.
In recent Android releases, the number of long-running binder processes has increased to the point that for 32-bit systems, there is a risk of running out of vmalloc space.
This patch set removes the persistent mapping of the binder buffers into kernel space. Instead, the binder driver creates temporary mappings with kmap() or kmap_atomic() to copy to or from the buffer only when necessary.
Todd Kjos (7):
binder: create userspace-to-binder-buffer copy function
binder: add functions to copy to/from binder buffers
binder: add function to copy binder object from buffer
binder: avoid kernel vm_area for buffer fixups
binder: remove kernel vm_area for buffer space
binder: remove user_buffer_offset
binder: use userspace pointer as base of buffer space
v2: remove casts as suggested by Dan Carpenter
v3: fix build-break when CONFIG_ANDROID_BINDER_IPC_SELFTEST enabled
drivers/android/Kconfig | 2 +- drivers/android/binder.c | 460 ++++++++++++++++++++++++++++++++++++++++++++++++++---------------------------- drivers/android/binder_alloc.c | 299 +++++++++++++++++++++++++++++++++++++-------------- drivers/android/binder_alloc.h | 47 ++++---- drivers/android/binder_alloc_selftest.c | 4 +- drivers/android/binder_trace.h | 2 +- 6 files changed, 536 insertions(+), 278 deletions(-)