OSDN Git Service

minigbm: amdgpu: make bo's created with SCANOUT flag mmapable
authorShirish S <shirish.s@amd.com>
Fri, 13 Oct 2017 04:24:03 +0000 (09:54 +0530)
committerchrome-bot <chrome-bot@chromium.org>
Sat, 14 Oct 2017 10:18:34 +0000 (03:18 -0700)
commit8317bc0658be27b66ebf0b745533adf0214fe3a2
treec1b765347d1afbacc456793656bb0d8aebd47baa
parente29a640dd6f26d50e29cabac2611bd97841c2101
minigbm: amdgpu: make bo's created with SCANOUT flag mmapable

amdgpu kenrel driver can mmap a 'bo' only if it has
AMDGPU_GEM_CREATE_CPU_ACCESS_REQUIRED  flag set.
This flag was not set in case if the 'bo' is used as a SCANOUT buffer,
for several reasons like it might impact performance etc.
But due to several requirements realted testing drm functionalitites
like atomicity, multi-planes etc., this restriction needs to be
removed.
Several known tests related to performance have been done after making
this change and none have shown glaring performance regressions.

However it should be noted that in case we find any performance related
regression in an un-tested scenario this patch needs to be reverted.

BUG=b:65297611
TEST=On Kahlee,
     UI comes up.
     GLMark2 & GLbench autotests show no performance regression
     atomictest -t multiplanes passes
     WebGL Aquarium

Change-Id: If629b64f3a14f843972b25d393a0a16058b3044e
Signed-off-by: Shirish S <shirish.s@amd.com>
Reviewed-on: https://chromium-review.googlesource.com/715037
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
amdgpu.c