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

Unified Diff: ui/ozone/platform/dri/hardware_display_controller.cc

Issue 838633002: [Ozone-DRI] Reuse framebuffer when re-enabling CRTC (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 5 years, 11 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
« no previous file with comments | « no previous file | ui/ozone/platform/dri/screen_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/ozone/platform/dri/hardware_display_controller.cc
diff --git a/ui/ozone/platform/dri/hardware_display_controller.cc b/ui/ozone/platform/dri/hardware_display_controller.cc
index 92e84a2a772f889aad75322ebcef1ab4d0c134e8..7ec4f0dcbc95c4e1f5cc0b4e7883a3fffd9b2db1 100644
--- a/ui/ozone/platform/dri/hardware_display_controller.cc
+++ b/ui/ozone/platform/dri/hardware_display_controller.cc
@@ -48,6 +48,7 @@ void HandlePageFlipEvent(int fd,
HardwareDisplayController::HardwareDisplayController(
scoped_ptr<CrtcController> controller)
: is_disabled_(true) {
+ memset(&mode_, 0, sizeof(mode_));
AddCrtc(controller.Pass());
}
@@ -75,12 +76,8 @@ bool HardwareDisplayController::Enable() {
TRACE_EVENT0("dri", "HDC::Enable");
DCHECK(!current_planes_.empty());
const OverlayPlane* primary = OverlayPlane::GetPrimaryPlane(current_planes_);
- DCHECK(primary->buffer.get());
- bool status = true;
- for (size_t i = 0; i < crtc_controllers_.size(); ++i)
- status &= crtc_controllers_[i]->Modeset(*primary, mode_);
- return status;
+ return Modeset(*primary, mode_);
}
void HardwareDisplayController::Disable() {
« no previous file with comments | « no previous file | ui/ozone/platform/dri/screen_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698