xf86-video-intel: src/sna/sna_driver.c

Chris Wilson ickle at kemper.freedesktop.org
Sat Oct 22 20:08:27 UTC 2016


 src/sna/sna_driver.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 90172d81ea762eeca4cfb3796fab83cff9f0acaa
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date:   Sat Oct 22 21:06:11 2016 +0100

    sna: Allow Option DPMS to switch on (but not off)
    
    We start off the system with the screens blanked, waiting the first
    dixSaveScreen unblank, where we then apply the accumulated modesets.
    This means we have to allow that even if Option DPMS off, and so we
    restrict the Option to only enable DPMS (then once enabled they will not
    turn off).
    
    References: https://bugs.freedesktop.org/show_bug.cgi?id=98375
    Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>

diff --git a/src/sna/sna_driver.c b/src/sna/sna_driver.c
index 3e9cf86..aa637c0 100644
--- a/src/sna/sna_driver.c
+++ b/src/sna/sna_driver.c
@@ -296,7 +296,7 @@ static void sna_dpms_set(ScrnInfoPtr scrn, int mode, int flags)
 
 	DBG(("%s(mode=%d, flags=%d), vtSema=%d => off?=%d\n",
 	     __FUNCTION__, mode, flags, scrn->vtSema, mode!=DPMSModeOn));
-	if (!scrn->vtSema || sna->flags & SNA_NO_DPMS)
+	if (!scrn->vtSema)
 		return;
 
 	/* Opencoded version of xf86DPMSSet().
@@ -308,7 +308,7 @@ static void sna_dpms_set(ScrnInfoPtr scrn, int mode, int flags)
 	 * back on.
 	 */
 	if (mode != DPMSModeOn) {
-		if (sna->mode.hidden == 0) {
+		if (sna->mode.hidden == 0 && !(sna->flags & SNA_NO_DPMS)) {
 			DBG(("%s: hiding %d outputs\n",
 			     __FUNCTION__, config->num_output));
 			for (i = 0; i < config->num_output; i++) {


More information about the xorg-commit mailing list