Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(789)

Unified Diff: ui/ozone/platform/drm/gpu/crtc_controller.cc

Issue 1418503012: [Ozone-DRM] Remove bool return value for SchedulePageFlip call (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/ozone/platform/drm/gpu/crtc_controller.cc
diff --git a/ui/ozone/platform/drm/gpu/crtc_controller.cc b/ui/ozone/platform/drm/gpu/crtc_controller.cc
index adc3c84c8b078523e86904ded17e666b2f74a924..758abcd0f2d2c761beecac5a4c3f214a73273429 100644
--- a/ui/ozone/platform/drm/gpu/crtc_controller.cc
+++ b/ui/ozone/platform/drm/gpu/crtc_controller.cc
@@ -32,7 +32,7 @@ CrtcController::~CrtcController() {
SetCursor(nullptr);
drm_->DisableCrtc(crtc_);
- SignalPageFlipRequest();
+ SignalPageFlipRequest(gfx::SwapResult::SWAP_ACK);
}
}
@@ -118,11 +118,6 @@ std::vector<uint32_t> CrtcController::GetCompatibleHardwarePlaneIds(
return drm_->plane_manager()->GetCompatibleHardwarePlaneIds(plane, crtc_);
}
-void CrtcController::PageFlipFailed() {
- pending_planes_.clear();
- SignalPageFlipRequest();
-}
-
void CrtcController::OnPageFlipEvent(unsigned int frame,
unsigned int seconds,
unsigned int useconds) {
@@ -133,7 +128,7 @@ void CrtcController::OnPageFlipEvent(unsigned int frame,
current_planes_.clear();
current_planes_.swap(pending_planes_);
spang 2015/10/29 20:59:20 I think it should be moved to SignalPageFlipReques
dnicoara 2015/10/30 14:59:31 Acknowledged.
- SignalPageFlipRequest();
+ SignalPageFlipRequest(gfx::SwapResult::SWAP_ACK);
}
bool CrtcController::SetCursor(const scoped_refptr<ScanoutBuffer>& buffer) {
@@ -167,7 +162,8 @@ bool CrtcController::ResetCursor() {
return status;
}
-void CrtcController::SignalPageFlipRequest() {
+void CrtcController::SignalPageFlipRequest(gfx::SwapResult result) {
+ pending_planes_.clear();
if (page_flip_request_.get()) {
spang 2015/10/29 20:59:20 When is this false?
dnicoara 2015/10/30 14:59:31 This was needed when HDC::SchedulePageFlip() was r
dnicoara 2015/10/30 17:21:59 Actually, sorry, you're right, it shouldn't be pos
// If another frame is queued up and available immediately, calling Signal()
// may result in a call to SchedulePageFlip(), which will override
@@ -175,7 +171,7 @@ void CrtcController::SignalPageFlipRequest() {
// locally to avoid deleting the object we are making a call on.
scoped_refptr<PageFlipRequest> last_request;
last_request.swap(page_flip_request_);
- last_request->Signal(gfx::SwapResult::SWAP_ACK);
+ last_request->Signal(result);
}
}

Powered by Google App Engine
This is Rietveld 408576698