diff options
author | Gurchetan Singh <gurchetansingh@chromium.org> | 2017-10-10 12:11:16 -0700 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2017-11-16 13:52:02 -0800 |
commit | 07d36cc464e6d20d08913856f50cb50c2c6877d4 (patch) | |
tree | 04fbc7b6c5bb2190f21b891a82aa2af1181a1a43 | |
parent | bc9a87d54c5296d467ead2b4ea35e317f00ee401 (diff) |
Revert "minigbm: Revert "minigbm: flush buffer instead of unmapping""
The reason the tests weren't passing is because DRM_IOCTL_I915_GEM_SET_DOMAIN
is required on x86 platforms when calling (*lock). A previous CLs added this.
BUG=b:67073097, b:67331142
TEST=
android.view.cts.SurfaceViewSyncTests
android.video.cts.VideoEncoderDecoderTest#testAvcGoog0Qual0720x0480
android.video.cts.VideoEncoderDecoderTest#testAvcGoog0Qual1280x0720
android.video.cts.VideoEncoderDecoderTest#testAvcGoog0Qual1920x1080
android.media.cts.EncodeDecodeTest#testVP8EncodeDecodeVideoFromSurfaceToSurface720p
android.media.cts.EncodeDecodeTest#testEncodeDecodeVideoFromPersistentSurfaceToSurface720p
android.media.cts.EncodeDecodeTest#testVP8EncodeDecodeVideoFromPersistentSurfaceToSurface720p
pass on Eve.
This reverts commit 14033e0013b5cc0ffc5af59dda7c377d46ec761d.
v2: Make lock_data[0] null after last (*unlock)(), because user may specify different
access regions in the next (*lock)().
Change-Id: Ia56ecd57acc4471b026c852b178d8bc0f189dec7
Reviewed-on: https://chromium-review.googlesource.com/710324
Commit-Ready: Gurchetan Singh <gurchetansingh@chromium.org>
Tested-by: Gurchetan Singh <gurchetansingh@chromium.org>
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
-rw-r--r-- | cros_gralloc/cros_gralloc_buffer.cc | 2 | ||||
-rw-r--r-- | gbm.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/cros_gralloc/cros_gralloc_buffer.cc b/cros_gralloc/cros_gralloc_buffer.cc index 7757069..47a13a2 100644 --- a/cros_gralloc/cros_gralloc_buffer.cc +++ b/cros_gralloc/cros_gralloc_buffer.cc @@ -90,7 +90,7 @@ int32_t cros_gralloc_buffer::unlock() if (!--lockcount_) { if (lock_data_[0]) { - drv_bo_unmap(bo_, lock_data_[0]); + drv_bo_flush(bo_, lock_data_[0]); lock_data_[0] = nullptr; } } @@ -249,7 +249,7 @@ PUBLIC void *gbm_bo_map(struct gbm_bo *bo, uint32_t x, uint32_t y, uint32_t widt PUBLIC void gbm_bo_unmap(struct gbm_bo *bo, void *map_data) { assert(bo); - drv_bo_unmap(bo->bo, map_data); + drv_bo_flush(bo->bo, map_data); } PUBLIC uint32_t gbm_bo_get_width(struct gbm_bo *bo) |