Another compile fix for kernel >= 5.8

With kernel 5.8, the return value of map_kernel_range_noflush()
was changed. This function now returns 0 on success (instead of
the number of successfully mapped pages).

This commit adjusts binder accordingly.
This commit is contained in:
Christian Hoff 2021-03-08 21:23:59 +01:00
parent 443f984b1a
commit 6ddae19459
1 changed files with 1 additions and 1 deletions

View File

@ -671,7 +671,7 @@ static int binder_update_page_range(struct binder_proc *proc, int allocate,
PAGE_SIZE, PAGE_KERNEL, page); PAGE_SIZE, PAGE_KERNEL, page);
flush_cache_vmap((unsigned long)page_addr, flush_cache_vmap((unsigned long)page_addr,
(unsigned long)page_addr + PAGE_SIZE); (unsigned long)page_addr + PAGE_SIZE);
if (ret != 1) { if (ret < 0) {
pr_err("%d: binder_alloc_buf failed to map page at %p in kernel\n", pr_err("%d: binder_alloc_buf failed to map page at %p in kernel\n",
proc->pid, page_addr); proc->pid, page_addr);
goto err_map_kernel_failed; goto err_map_kernel_failed;