Messages in this thread Patch in this message | | | Date | Mon, 15 Nov 2021 20:09:09 -0000 | From | "tip-bot2 for Lucas De Marchi" <> | Subject | [tip: x86/mm] drm/i915/gem: Stop using PAGE_KERNEL_IO |
| |
The following commit has been merged into the x86/mm branch of tip:
Commit-ID: 6b2a2138cf36e67783884058c772bfeb63a999ad Gitweb: https://git.kernel.org/tip/6b2a2138cf36e67783884058c772bfeb63a999ad Author: Lucas De Marchi <lucas.demarchi@intel.com> AuthorDate: Thu, 21 Oct 2021 11:15:10 -07:00 Committer: Dave Hansen <dave.hansen@linux.intel.com> CommitterDate: Mon, 15 Nov 2021 10:31:49 -08:00
drm/i915/gem: Stop using PAGE_KERNEL_IO
PAGE_KERNEL_IO is only defined for x86 and nowadays is the same as PAGE_KERNEL. It was different for some time, OR'ing a `_PAGE_IOMAP` flag in commit be43d72835ba ("x86: add _PAGE_IOMAP pte flag for IO mappings"). This got removed in commit f955371ca9d3 ("x86: remove the Xen-specific _PAGE_IOMAP PTE flag"), so today they are just the same.
This is the same that was done in commit ac96b5566926 ("io-mapping.h: s/PAGE_KERNEL_IO/PAGE_KERNEL/").
There is a subsequent commit with 'Fixes: ac96b5566926 ("io-mapping.h: s/PAGE_KERNEL_IO/PAGE_KERNEL/")' - but that is not relevant here since is it's actually fixing the different names for pgprot_writecombine(), which we also don't have today since all archs expose pgprot_writecombine(). Microblaze, mentioned in that discussion, gained pgprot_writecombine() in commit 97ccedd793ac ("microblaze: Provide pgprot_device/writecombine macros for nommu").
So, just use PAGE_KERNEL, and just use pgprot_writecombine().
Link: https://patchwork.freedesktop.org/patch/msgid/20211020090625.1037517-1-lucas.demarchi@intel.com Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com> Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Acked-by: Andy Lutomirski <luto@kernel.org> Link: https://lkml.kernel.org/r/20211021181511.1533377-2-lucas.demarchi@intel.com --- drivers/gpu/drm/i915/gem/i915_gem_pages.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/i915/gem/i915_gem_pages.c b/drivers/gpu/drm/i915/gem/i915_gem_pages.c index 8eb1c3a..68fe183 100644 --- a/drivers/gpu/drm/i915/gem/i915_gem_pages.c +++ b/drivers/gpu/drm/i915/gem/i915_gem_pages.c @@ -289,7 +289,7 @@ static void *i915_gem_object_map_page(struct drm_i915_gem_object *obj, pgprot = PAGE_KERNEL; break; case I915_MAP_WC: - pgprot = pgprot_writecombine(PAGE_KERNEL_IO); + pgprot = pgprot_writecombine(PAGE_KERNEL); break; } @@ -333,7 +333,7 @@ static void *i915_gem_object_map_pfn(struct drm_i915_gem_object *obj, i = 0; for_each_sgt_daddr(addr, iter, obj->mm.pages) pfns[i++] = (iomap + addr) >> PAGE_SHIFT; - vaddr = vmap_pfn(pfns, n_pfn, pgprot_writecombine(PAGE_KERNEL_IO)); + vaddr = vmap_pfn(pfns, n_pfn, pgprot_writecombine(PAGE_KERNEL)); if (pfns != stack) kvfree(pfns);
| |