diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2017-11-16 12:10:59 -0500 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2017-11-16 12:10:59 -0500 |
| commit | 2bf16b7a73caf3435f782e4170cfe563675e10f9 (patch) | |
| tree | 7f4c5b28a02f08c4d6fd69dd43db5872b07c20c4 /drivers/android | |
| parent | b9743042b3d31fed271ae19aee79dd86817904f0 (diff) | |
| parent | f13d1a8a801dae552ef495c84a223280586a9f67 (diff) | |
Merge tag 'char-misc-4.15-rc1' of ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc
Pull char/misc updates from Greg KH:
"Here is the big set of char/misc and other driver subsystem patches
for 4.15-rc1.
There are small changes all over here, hyperv driver updates, pcmcia
driver updates, w1 driver updats, vme driver updates, nvmem driver
updates, and lots of other little one-off driver updates as well. The
shortlog has the full details.
All of these have been in linux-next for quite a while with no
reported issues"
* tag 'char-misc-4.15-rc1' of ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: (90 commits)
VME: Return -EBUSY when DMA list in use
w1: keep balance of mutex locks and refcnts
MAINTAINERS: Update VME subsystem tree.
nvmem: sunxi-sid: add support for A64/H5's SID controller
nvmem: imx-ocotp: Update module description
nvmem: imx-ocotp: Enable i.MX7D OTP write support
nvmem: imx-ocotp: Add i.MX7D timing write clock setup support
nvmem: imx-ocotp: Move i.MX6 write clock setup to dedicated function
nvmem: imx-ocotp: Add support for banked OTP addressing
nvmem: imx-ocotp: Pass parameters via a struct
nvmem: imx-ocotp: Restrict OTP write to IMX6 processors
nvmem: uniphier: add UniPhier eFuse driver
dt-bindings: nvmem: add description for UniPhier eFuse
nvmem: set nvmem->owner to nvmem->dev->driver->owner if unset
nvmem: qfprom: fix different address space warnings of sparse
nvmem: mtk-efuse: fix different address space warnings of sparse
nvmem: mtk-efuse: use stack for nvmem_config instead of malloc'ing it
nvmem: imx-iim: use stack for nvmem_config instead of malloc'ing it
thunderbolt: tb: fix use after free in tb_activate_pcie_devices
MAINTAINERS: Add git tree for Thunderbolt development
...
Diffstat (limited to 'drivers/android')
| -rw-r--r-- | drivers/android/binder.c | 2 | ||||
| -rw-r--r-- | drivers/android/binder_alloc.c | 18 |
2 files changed, 9 insertions, 11 deletions
diff --git a/drivers/android/binder.c b/drivers/android/binder.c index 7255f94ded30..a73596a4f804 100644 --- a/drivers/android/binder.c +++ b/drivers/android/binder.c | |||
| @@ -2192,7 +2192,7 @@ static void binder_transaction_buffer_release(struct binder_proc *proc, | |||
| 2192 | off_start, | 2192 | off_start, |
| 2193 | offp - off_start); | 2193 | offp - off_start); |
| 2194 | if (!parent) { | 2194 | if (!parent) { |
| 2195 | pr_err("transaction release %d bad parent offset", | 2195 | pr_err("transaction release %d bad parent offset\n", |
| 2196 | debug_id); | 2196 | debug_id); |
| 2197 | continue; | 2197 | continue; |
| 2198 | } | 2198 | } |
diff --git a/drivers/android/binder_alloc.c b/drivers/android/binder_alloc.c index c2819a3d58a6..6f6f745605af 100644 --- a/drivers/android/binder_alloc.c +++ b/drivers/android/binder_alloc.c | |||
| @@ -186,12 +186,12 @@ struct binder_buffer *binder_alloc_prepare_to_free(struct binder_alloc *alloc, | |||
| 186 | } | 186 | } |
| 187 | 187 | ||
| 188 | static int binder_update_page_range(struct binder_alloc *alloc, int allocate, | 188 | static int binder_update_page_range(struct binder_alloc *alloc, int allocate, |
| 189 | void *start, void *end, | 189 | void *start, void *end) |
| 190 | struct vm_area_struct *vma) | ||
| 191 | { | 190 | { |
| 192 | void *page_addr; | 191 | void *page_addr; |
| 193 | unsigned long user_page_addr; | 192 | unsigned long user_page_addr; |
| 194 | struct binder_lru_page *page; | 193 | struct binder_lru_page *page; |
| 194 | struct vm_area_struct *vma = NULL; | ||
| 195 | struct mm_struct *mm = NULL; | 195 | struct mm_struct *mm = NULL; |
| 196 | bool need_mm = false; | 196 | bool need_mm = false; |
| 197 | 197 | ||
| @@ -215,7 +215,7 @@ static int binder_update_page_range(struct binder_alloc *alloc, int allocate, | |||
| 215 | } | 215 | } |
| 216 | } | 216 | } |
| 217 | 217 | ||
| 218 | if (!vma && need_mm && mmget_not_zero(alloc->vma_vm_mm)) | 218 | if (need_mm && mmget_not_zero(alloc->vma_vm_mm)) |
| 219 | mm = alloc->vma_vm_mm; | 219 | mm = alloc->vma_vm_mm; |
| 220 | 220 | ||
| 221 | if (mm) { | 221 | if (mm) { |
| @@ -437,7 +437,7 @@ struct binder_buffer *binder_alloc_new_buf_locked(struct binder_alloc *alloc, | |||
| 437 | if (end_page_addr > has_page_addr) | 437 | if (end_page_addr > has_page_addr) |
| 438 | end_page_addr = has_page_addr; | 438 | end_page_addr = has_page_addr; |
| 439 | ret = binder_update_page_range(alloc, 1, | 439 | ret = binder_update_page_range(alloc, 1, |
| 440 | (void *)PAGE_ALIGN((uintptr_t)buffer->data), end_page_addr, NULL); | 440 | (void *)PAGE_ALIGN((uintptr_t)buffer->data), end_page_addr); |
| 441 | if (ret) | 441 | if (ret) |
| 442 | return ERR_PTR(ret); | 442 | return ERR_PTR(ret); |
| 443 | 443 | ||
| @@ -478,7 +478,7 @@ struct binder_buffer *binder_alloc_new_buf_locked(struct binder_alloc *alloc, | |||
| 478 | err_alloc_buf_struct_failed: | 478 | err_alloc_buf_struct_failed: |
| 479 | binder_update_page_range(alloc, 0, | 479 | binder_update_page_range(alloc, 0, |
| 480 | (void *)PAGE_ALIGN((uintptr_t)buffer->data), | 480 | (void *)PAGE_ALIGN((uintptr_t)buffer->data), |
| 481 | end_page_addr, NULL); | 481 | end_page_addr); |
| 482 | return ERR_PTR(-ENOMEM); | 482 | return ERR_PTR(-ENOMEM); |
| 483 | } | 483 | } |
| 484 | 484 | ||
| @@ -562,8 +562,7 @@ static void binder_delete_free_buffer(struct binder_alloc *alloc, | |||
| 562 | alloc->pid, buffer->data, | 562 | alloc->pid, buffer->data, |
| 563 | prev->data, next ? next->data : NULL); | 563 | prev->data, next ? next->data : NULL); |
| 564 | binder_update_page_range(alloc, 0, buffer_start_page(buffer), | 564 | binder_update_page_range(alloc, 0, buffer_start_page(buffer), |
| 565 | buffer_start_page(buffer) + PAGE_SIZE, | 565 | buffer_start_page(buffer) + PAGE_SIZE); |
| 566 | NULL); | ||
| 567 | } | 566 | } |
| 568 | list_del(&buffer->entry); | 567 | list_del(&buffer->entry); |
| 569 | kfree(buffer); | 568 | kfree(buffer); |
| @@ -600,8 +599,7 @@ static void binder_free_buf_locked(struct binder_alloc *alloc, | |||
| 600 | 599 | ||
| 601 | binder_update_page_range(alloc, 0, | 600 | binder_update_page_range(alloc, 0, |
| 602 | (void *)PAGE_ALIGN((uintptr_t)buffer->data), | 601 | (void *)PAGE_ALIGN((uintptr_t)buffer->data), |
| 603 | (void *)(((uintptr_t)buffer->data + buffer_size) & PAGE_MASK), | 602 | (void *)(((uintptr_t)buffer->data + buffer_size) & PAGE_MASK)); |
| 604 | NULL); | ||
| 605 | 603 | ||
| 606 | rb_erase(&buffer->rb_node, &alloc->allocated_buffers); | 604 | rb_erase(&buffer->rb_node, &alloc->allocated_buffers); |
| 607 | buffer->free = 1; | 605 | buffer->free = 1; |
| @@ -984,7 +982,7 @@ binder_shrink_scan(struct shrinker *shrink, struct shrink_control *sc) | |||
| 984 | return ret; | 982 | return ret; |
| 985 | } | 983 | } |
| 986 | 984 | ||
| 987 | struct shrinker binder_shrinker = { | 985 | static struct shrinker binder_shrinker = { |
| 988 | .count_objects = binder_shrink_count, | 986 | .count_objects = binder_shrink_count, |
| 989 | .scan_objects = binder_shrink_scan, | 987 | .scan_objects = binder_shrink_scan, |
| 990 | .seeks = DEFAULT_SEEKS, | 988 | .seeks = DEFAULT_SEEKS, |
