From 5c076707336319ef2649f1c62f977b015ff583fa Mon Sep 17 00:00:00 2001 From: "kalyan.kondapally" Date: Mon, 10 Aug 2015 11:37:10 -0700 Subject: [PATCH] Atomic: Notify Watcher to observe device fd we always block on the main thread till the FD becomes readable. With non-atomic code path, we always wait on a worker thread to see if the device fd has become readable. We want to do the same with Atomic, notify watcher to observe if the device fd is readable in a separate thread (respecting is_sync value) instead of blocking main thread. BUG= Review URL: https://codereview.chromium.org/1282723002 Cr-Commit-Position: refs/heads/master@{#342651} --- ui/ozone/platform/drm/gpu/drm_device.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ui/ozone/platform/drm/gpu/drm_device.cc b/ui/ozone/platform/drm/gpu/drm_device.cc index 5df2b28d5133..8dc6e8a814e9 100644 --- a/ui/ozone/platform/drm/gpu/drm_device.cc +++ b/ui/ozone/platform/drm/gpu/drm_device.cc @@ -559,6 +559,9 @@ bool DrmDevice::CommitProperties(drmModePropertySet* properties, return true; page_flip_manager_->RegisterCallback(id, callback); + if (watcher_) + watcher_->SetPaused(is_sync); + // If the flip was requested synchronous or if no watcher has been installed // yet, then synchronously handle the page flip events. if (is_sync || !watcher_) { -- 2.11.4.GIT