--- linux-6.3/drivers/gpu/drm/i915/gem/i915_gem_pages.c.vanilla	2023-04-25 20:43:53.009300408 +0200
+++ linux-6.3/drivers/gpu/drm/i915/gem/i915_gem_pages.c	2023-04-25 20:48:42.484325474 +0200
@@ -300,7 +300,11 @@
 		pgprot = PAGE_KERNEL;
 		break;
 	case I915_MAP_WC:
+#ifdef PAGE_KERNEL_IO
 		pgprot = pgprot_writecombine(PAGE_KERNEL_IO);
+#else
+		pgprot = pgprot_writecombine(PAGE_KERNEL);
+#endif
 		break;
 	}
 
@@ -344,7 +348,11 @@
 	i = 0;
 	for_each_sgt_daddr(addr, iter, obj->mm.pages)
 		pfns[i++] = (iomap + addr) >> PAGE_SHIFT;
+#ifdef PAGE_KERNEL_IO
 	vaddr = vmap_pfn(pfns, n_pfn, pgprot_writecombine(PAGE_KERNEL_IO));
+#else
+	vaddr = vmap_pfn(pfns, n_pfn, pgprot_writecombine(PAGE_KERNEL));
+#endif
 	if (pfns != stack)
 		kvfree(pfns);
 
