Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm: Only set DPMS ON when actually configuring a mode

In drm_crtc_helper_set_config, instead of always forcing all outputs
to DRM_MODE_DPMS_ON, only set them if the CRTC is actually getting a
mode set, as any mode set will turn all outputs on.

This fixes https://lkml.org/lkml/2011/1/24/457

Signed-off-by: Keith Packard <keithp@keithp.com>
Cc: stable@kernel.org (2.6.37)
Reported-and-tested-by: Carlos R. Mafra <crmafra2@gmail.com>
Tested-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Keith Packard and committed by
Linus Torvalds
811aaa55 89840966

+6 -6
+6 -6
drivers/gpu/drm/drm_crtc_helper.c
··· 665 665 ret = -EINVAL; 666 666 goto fail; 667 667 } 668 + DRM_DEBUG_KMS("Setting connector DPMS state to on\n"); 669 + for (i = 0; i < set->num_connectors; i++) { 670 + DRM_DEBUG_KMS("\t[CONNECTOR:%d:%s] set DPMS on\n", set->connectors[i]->base.id, 671 + drm_get_connector_name(set->connectors[i])); 672 + set->connectors[i]->dpms = DRM_MODE_DPMS_ON; 673 + } 668 674 } 669 675 drm_helper_disable_unused_functions(dev); 670 676 } else if (fb_changed) { ··· 686 680 set->crtc->fb = old_fb; 687 681 goto fail; 688 682 } 689 - } 690 - DRM_DEBUG_KMS("Setting connector DPMS state to on\n"); 691 - for (i = 0; i < set->num_connectors; i++) { 692 - DRM_DEBUG_KMS("\t[CONNECTOR:%d:%s] set DPMS on\n", set->connectors[i]->base.id, 693 - drm_get_connector_name(set->connectors[i])); 694 - set->connectors[i]->dpms = DRM_MODE_DPMS_ON; 695 683 } 696 684 697 685 kfree(save_connectors);