The patch titled Subject: drm/i915: stop using kmap in i915_gem_object_map has been added to the -mm tree. Its filename is drm-i915-stop-using-kmap-in-i915_gem_object_map.patch This patch should soon appear at https://ozlabs.org/~akpm/mmots/broken-out/drm-i915-stop-using-kmap-in-i915_gem_object_map.patch and later at https://ozlabs.org/~akpm/mmotm/broken-out/drm-i915-stop-using-kmap-in-i915_gem_object_map.patch Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/process/submit-checklist.rst when testing your code *** The -mm tree is included into linux-next and is updated there every 3-4 working days ------------------------------------------------------ From: Christoph Hellwig <hch@xxxxxx> Subject: drm/i915: stop using kmap in i915_gem_object_map kmap for !PageHighmem is just a convoluted way to say page_address, and kunmap is a no-op in that case. Link: https://lkml.kernel.org/r/20201002122204.1534411-8-hch@xxxxxx Signed-off-by: Christoph Hellwig <hch@xxxxxx> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@xxxxxxxxx> Cc: Boris Ostrovsky <boris.ostrovsky@xxxxxxxxxx> Cc: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> Cc: Jani Nikula <jani.nikula@xxxxxxxxxxxxxxx> Cc: Joonas Lahtinen <joonas.lahtinen@xxxxxxxxxxxxxxx> Cc: Juergen Gross <jgross@xxxxxxxx> Cc: Matthew Auld <matthew.auld@xxxxxxxxx> Cc: "Matthew Wilcox (Oracle)" <willy@xxxxxxxxxxxxx> Cc: Minchan Kim <minchan@xxxxxxxxxx> Cc: Nitin Gupta <ngupta@xxxxxxxxxx> Cc: Peter Zijlstra <peterz@xxxxxxxxxxxxx> Cc: Rodrigo Vivi <rodrigo.vivi@xxxxxxxxx> Cc: Stefano Stabellini <sstabellini@xxxxxxxxxx> Cc: Uladzislau Rezki (Sony) <urezki@xxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- drivers/gpu/drm/i915/gem/i915_gem_pages.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) --- a/drivers/gpu/drm/i915/gem/i915_gem_pages.c~drm-i915-stop-using-kmap-in-i915_gem_object_map +++ a/drivers/gpu/drm/i915/gem/i915_gem_pages.c @@ -162,8 +162,6 @@ static void unmap_object(struct drm_i915 { if (is_vmalloc_addr(ptr)) vunmap(ptr); - else - kunmap(kmap_to_page(ptr)); } struct sg_table * @@ -277,11 +275,10 @@ static void *i915_gem_object_map(struct * forever. * * So if the page is beyond the 32b boundary, make an explicit - * vmap. On 64b, this check will be optimised away as we can - * directly kmap any page on the system. + * vmap. */ if (!PageHighMem(page)) - return kmap(page); + return page_address(page); } mem = stack; _ Patches currently in -mm which might be from hch@xxxxxx are mm-add-a-vm_map_put_pages-flag-for-vmap.patch mm-add-a-vmap_pfn-function.patch mm-allow-a-null-fn-callback-in-apply_to_page_range.patch zsmalloc-switch-from-alloc_vm_area-to-get_vm_area.patch drm-i915-use-vmap-in-shmem_pin_map.patch drm-i915-stop-using-kmap-in-i915_gem_object_map.patch drm-i915-use-vmap-in-i915_gem_object_map.patch xen-xenbus-use-apply_to_page_range-directly-in-xenbus_map_ring_pv.patch x86-xen-open-code-alloc_vm_area-in-arch_gnttab_valloc.patch mm-remove-alloc_vm_area.patch mm-cleanup-the-gfp_mask-handling-in-__vmalloc_area_node.patch mm-remove-the-filename-in-the-top-of-file-comment-in-vmallocc.patch