summaryrefslogtreecommitdiff
path: root/kde-plasma/kwin/files/kwin-5.27.8-crashfix.patch
blob: e8d6cca37fee588f434f92f65cffebd3d236a8cf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
From f099b206b6d8cffee1b410a51e540d3750c4a0af Mon Sep 17 00:00:00 2001
From: Xaver Hugl <xaver.hugl@gmail.com>
Date: Tue, 12 Sep 2023 16:23:15 +0200
Subject: [PATCH] backends/drm: check activePending instead of active for when
 applying a new gamma ramp is allowed

The crtc may not be set yet in some cases

BUG: 471562
(cherry picked from commit 57fae99f33aa5d092ebb82e9924fbd7fbb932fc7)
---
 src/backends/drm/drm_output.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/backends/drm/drm_output.cpp b/src/backends/drm/drm_output.cpp
index 558de1f7c4b..c55c4c1832f 100644
--- a/src/backends/drm/drm_output.cpp
+++ b/src/backends/drm/drm_output.cpp
@@ -466,7 +466,7 @@ DrmOutputLayer *DrmOutput::primaryLayer() const
 
 bool DrmOutput::setGammaRamp(const std::shared_ptr<ColorTransformation> &transformation)
 {
-    if (!m_pipeline->active()) {
+    if (!m_pipeline->activePending()) {
         return false;
     }
     m_pipeline->setGammaRamp(transformation);
@@ -483,7 +483,7 @@ bool DrmOutput::setGammaRamp(const std::shared_ptr<ColorTransformation> &transfo
 
 bool DrmOutput::setCTM(const QMatrix3x3 &ctm)
 {
-    if (!m_pipeline->active()) {
+    if (!m_pipeline->activePending()) {
         return false;
     }
     m_pipeline->setCTM(ctm);
-- 
GitLab