Home Home > GIT Browse > SLE12-SP3-AZURE
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Zimmermann <tzimmermann@suse.de>2019-05-14 10:13:41 +0200
committerThomas Zimmermann <tzimmermann@suse.de>2019-05-14 10:36:20 +0200
commitd3a89a35cde90874b0efdae4cec29935256051c1 (patch)
tree6ab0fc991bafaf525bcded9d263ad9563cbccb67
parent6e38c827f56d32b8af3745ae1ddecf51ae6e1e63 (diff)
drm/fb-helper: dpms_legacy(): Only set on connectors in use (bnc#1106929)
-rw-r--r--patches.fixes/0002-drm-fb-helper-dpms_legacy-Only-set-on-connectors-in-.patch54
-rw-r--r--series.conf1
2 files changed, 55 insertions, 0 deletions
diff --git a/patches.fixes/0002-drm-fb-helper-dpms_legacy-Only-set-on-connectors-in-.patch b/patches.fixes/0002-drm-fb-helper-dpms_legacy-Only-set-on-connectors-in-.patch
new file mode 100644
index 0000000000..3d3aa9c0ff
--- /dev/null
+++ b/patches.fixes/0002-drm-fb-helper-dpms_legacy-Only-set-on-connectors-in-.patch
@@ -0,0 +1,54 @@
+From 65a102f68005891d7f39354cfd79099908df6d51 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Noralf=20Tr=C3=B8nnes?= <noralf@tronnes.org>
+Date: Tue, 26 Mar 2019 18:55:32 +0100
+Subject: drm/fb-helper: dpms_legacy(): Only set on connectors in use
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+Git-commit: 65a102f68005891d7f39354cfd79099908df6d51
+Patch-mainline: v5.2-rc1
+References: bnc#1106929
+
+For each enabled crtc the functions sets dpms on all registered connectors.
+Limit this to only doing it once and on the connectors actually in use.
+
+Signed-off-by: Noralf Trønnes <noralf@tronnes.org>
+Fixes: 023eb571a1d0 ("drm: correctly update connector DPMS status in drm_fb_helper")
+Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
+Link: https://patchwork.freedesktop.org/patch/msgid/20190326175546.18126-3-noralf@tronnes.org
+Acked-by: Thomas Zimmermann <tzimmermann@suse.de>
+---
+ drivers/gpu/drm/drm_fb_helper.c | 11 +++++------
+ 1 file changed, 5 insertions(+), 6 deletions(-)
+
+--- a/drivers/gpu/drm/drm_fb_helper.c
++++ b/drivers/gpu/drm/drm_fb_helper.c
+@@ -560,8 +560,8 @@ static void drm_fb_helper_dpms(struct fb
+ {
+ struct drm_fb_helper *fb_helper = info->par;
+ struct drm_device *dev = fb_helper->dev;
+- struct drm_crtc *crtc;
+ struct drm_connector *connector;
++ struct drm_mode_set *modeset;
+ int i, j;
+
+ /*
+@@ -574,14 +574,13 @@ static void drm_fb_helper_dpms(struct fb
+ }
+
+ for (i = 0; i < fb_helper->crtc_count; i++) {
+- crtc = fb_helper->crtc_info[i].mode_set.crtc;
++ modeset = &fb_helper->crtc_info[i].mode_set;
+
+- if (!crtc->enabled)
++ if (!modeset->crtc->enabled)
+ continue;
+
+- /* Walk the connectors & encoders on this fb turning them on/off */
+- for (j = 0; j < fb_helper->connector_count; j++) {
+- connector = fb_helper->connector_info[j]->connector;
++ for (j = 0; j < modeset->num_connectors; j++) {
++ connector = modeset->connectors[j];
+ connector->funcs->dpms(connector, dpms_mode);
+ drm_object_property_set_value(&connector->base,
+ dev->mode_config.dpms_property, dpms_mode);
diff --git a/series.conf b/series.conf
index 02001fed1d..776a3a91b8 100644
--- a/series.conf
+++ b/series.conf
@@ -25303,6 +25303,7 @@
patches.drivers/Bluetooth-hidp-fix-buffer-overflow.patch
patches.fixes/0001-UAS-fix-alignment-of-scatter-gather-segments.patch
patches.fixes/0001-drm-i915-Fix-I915_EXEC_RING_MASK.patch
+ patches.fixes/0002-drm-fb-helper-dpms_legacy-Only-set-on-connectors-in-.patch
# davem/net-next
patches.drivers/ibmvnic-Report-actual-backing-device-speed-and-duple.patch