drm/i915/gem: Prevent using pgprot_writecombine() if PAT is not supported
authorChris Wilson <chris@chris-wilson.co.uk>
Tue, 15 Sep 2020 09:14:16 +0000 (10:14 +0100)
committerRodrigo Vivi <rodrigo.vivi@intel.com>
Wed, 30 Sep 2020 18:24:20 +0000 (14:24 -0400)
commitba2ebf605d5f32a9be0f7b05d3174bbc501b83fe
treeb98432d7c7875954ecfe05dad6bff70ba9510cee
parent4caf017ee93703ba1c4504f3d73b50e6bbd4249e
drm/i915/gem: Prevent using pgprot_writecombine() if PAT is not supported

Let's not try and use PAT attributes for I915_MAP_WC if the CPU doesn't
support PAT.

Fixes: 6056e50033d9 ("drm/i915/gem: Support discontiguous lmem object maps")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Cc: <stable@vger.kernel.org> # v5.6+
Link: https://patchwork.freedesktop.org/patch/msgid/20200915091417.4086-2-chris@chris-wilson.co.uk
(cherry picked from commit 121ba69ffddc60df11da56f6d5b29bdb45c8eb80)
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
drivers/gpu/drm/i915/gem/i915_gem_pages.c