debian/changelog                     |    5 ++++
 debian/patches/fix-no-backlight.diff |   38 +++++++++++++++++++++++++++++++++++
 debian/patches/series                |    1 
 3 files changed, 44 insertions(+)

New commits:
commit 9d237d1aa2a2d7561ce4ceaf49e06296b1d6bfd0
Author: Timo Aaltonen <tjaal...@debian.org>
Date:   Mon Oct 20 10:29:28 2014 +0300

    fix-no-backlight.diff: Don't let backlight switch off when cycling through 
display modes. (LP: #1373776)

diff --git a/debian/changelog b/debian/changelog
index 7fa7a26..1440041 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,7 +1,12 @@
 xserver-xorg-video-intel (2:2.99.910-0ubuntu1.2) UNRELEASED; urgency=low
 
+  [ Maarten Lankhorst ]
   * Fix black screen with SNA. (LP: #1365695)
 
+  [ Timo Aaltonen ]
+  * fix-no-backlight.diff: Don't let backlight switch off when cycling
+    through display modes. (LP: #1373776)
+
  -- Maarten Lankhorst <maarten.lankho...@ubuntu.com>  Mon, 22 Sep 2014 
11:26:22 +0200
 
 xserver-xorg-video-intel (2:2.99.910-0ubuntu1.1) trusty; urgency=medium
diff --git a/debian/patches/fix-no-backlight.diff 
b/debian/patches/fix-no-backlight.diff
new file mode 100644
index 0000000..0a73239
--- /dev/null
+++ b/debian/patches/fix-no-backlight.diff
@@ -0,0 +1,38 @@
+Index: xserver-xorg-video-intel-2.99.910/src/sna/sna_display.c
+===================================================================
+--- xserver-xorg-video-intel-2.99.910.orig/src/sna/sna_display.c       
2014-09-26 16:19:42.420356000 +0800
++++ xserver-xorg-video-intel-2.99.910/src/sna/sna_display.c    2014-09-26 
16:20:00.001464561 +0800
+@@ -2386,8 +2386,12 @@
+                                                  
sna_output->backlight_active_level);
+       } else {
+               /* Only save the current backlight value if we're going from on 
to off. */
+-              if (oldmode == DPMSModeOn)
+-                      sna_output->backlight_active_level = 
sna_output_backlight_get(output);
++      if (oldmode == DPMSModeOn) {
++              int brightness = sna_output_backlight_get(output);
++              if (brightness > 0) {
++                      sna_output->backlight_active_level = brightness;
++              }
++      }
+               sna_output_backlight_set(output, 0);
+       }
+ }
+diff --git a/src/uxa/intel_display.c b/src/uxa/intel_display.c
+index 39d8507..51727a5 100644
+--- a/src/uxa/intel_display.c
++++ b/src/uxa/intel_display.c
+@@ -1095,8 +1095,12 @@ intel_output_dpms_backlight(xf86OutputPtr output, int 
oldmode, int mode)
+                                                  
intel_output->backlight_active_level);
+       } else {
+               /* Only save the current backlight value if we're going from on 
to off. */
+-              if (oldmode == DPMSModeOn)
+-                      intel_output->backlight_active_level = 
intel_output_backlight_get(output);
++      if (oldmode == DPMSModeOn) {
++              int brightness = intel_output_backlight_get(output);
++              if (brightness > 0) {
++                      intel_output->backlight_active_level = brightness;
++              }
++      }
+               intel_output_backlight_set(output, 0);
+       }
+ }
diff --git a/debian/patches/series b/debian/patches/series
index f6330ab..1ddb42c 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -9,3 +9,4 @@ add-names-brw.diff
 
 sna-freescreen.diff
 disable-outputs-when-slaved.patch
+fix-no-backlight.diff


-- 
To UNSUBSCRIBE, email to debian-x-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/e1xg7pk-0001ug...@moszumanska.debian.org

Reply via email to