[mutter/benzea/gamma-fix-master: 5/7] kms: Apply gamma curve after configuring CRTCs
- From: Benjamin Berg <bberg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/benzea/gamma-fix-master: 5/7] kms: Apply gamma curve after configuring CRTCs
- Date: Fri, 28 Aug 2020 18:16:52 +0000 (UTC)
commit fbbfb60034e79749dace0ba03764acc70b20636e
Author: Benjamin Berg <bberg redhat com>
Date: Thu Aug 27 14:57:36 2020 +0200
kms: Apply gamma curve after configuring CRTCs
Since commit 2e5b767c0 (gpu/kms: Turn off CRTCs as well for DPMS) we
turn off the CRTCs. This has the undesired side effect that (at least
currently) updates the gamma cruves are lost. While this can be
considered a kernel issue, it has the major side effect of breaking
Night Light in ugly ways.
To allow fixing this, set the gamma curve after configuring the CRTC.
This is a prerequisite so that we can re-submit the gamma curve at the
same time as configuring the CRTC.
See: https://gitlab.gnome.org/GNOME/mutter/-/issues/1392
src/backends/native/meta-kms-impl-simple.c | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
---
diff --git a/src/backends/native/meta-kms-impl-simple.c b/src/backends/native/meta-kms-impl-simple.c
index 5aa7adc08e..ea41840732 100644
--- a/src/backends/native/meta-kms-impl-simple.c
+++ b/src/backends/native/meta-kms-impl-simple.c
@@ -956,13 +956,6 @@ meta_kms_impl_simple_process_update (MetaKmsImpl *impl,
&error))
goto err_planes_not_assigned;
- if (!process_entries (impl,
- update,
- meta_kms_update_get_crtc_gammas (update),
- process_crtc_gamma,
- &error))
- goto err_planes_not_assigned;
-
failed_planes = process_plane_assignments (impl, update);
if (failed_planes)
{
@@ -978,6 +971,13 @@ meta_kms_impl_simple_process_update (MetaKmsImpl *impl,
&error))
goto err_planes_assigned;
+ if (!process_entries (impl,
+ update,
+ meta_kms_update_get_crtc_gammas (update),
+ process_crtc_gamma,
+ &error))
+ goto err_planes_not_assigned;
+
return meta_kms_feedback_new_passed ();
err_planes_not_assigned:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]