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

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

Issue 1279703004: Ozone: HDC should only keep track of planes owned by it’s crtc controllers (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix comments Created 5 years, 4 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 34ec0668fac31c61643a358ba42a7e87ca88e409..e4d1049f317dca99bd754fa60200f9ae7f5bc40c 100644
--- a/ui/ozone/platform/drm/gpu/crtc_controller.cc
+++ b/ui/ozone/platform/drm/gpu/crtc_controller.cc
@@ -22,6 +22,15 @@ CrtcController::CrtcController(const scoped_refptr<DrmDevice>& drm,
CrtcController::~CrtcController() {
if (!is_disabled_) {
+ const ScopedVector<HardwareDisplayPlane>& all_planes =
+ drm_->plane_manager()->planes();
+ for (auto* plane : all_planes) {
+ if (plane->owning_crtc() == crtc_) {
+ plane->set_owning_crtc(0);
+ plane->set_in_use(false);
+ }
+ }
+
SetCursor(nullptr);
drm_->DisableCrtc(crtc_);
SignalPageFlipRequest();

Powered by Google App Engine
This is Rietveld 408576698