summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2017-10-16 05:08:39 +0100
committerDave Airlie <airlied@redhat.com>2017-11-23 12:45:30 +1000
commitb5f053882ff19a8ce4a3cbc66a136b8bc5e7094f (patch)
tree221e1b2cd07cd6509b74ff281658c2a1bab91750 /drivers
parent66660d4cf21b7dfcb258d8a51734963802693796 (diff)
downloadlinux-stable-b5f053882ff19a8ce4a3cbc66a136b8bc5e7094f.tar.gz
linux-stable-b5f053882ff19a8ce4a3cbc66a136b8bc5e7094f.tar.bz2
linux-stable-b5f053882ff19a8ce4a3cbc66a136b8bc5e7094f.zip
drm/fb: add support for not enabling fbcon on non-desktop displays [v2]
We don't want fbcon to get used on non-desktop dislays, don't pass them as enabled connectors to the fb helper setup. This prevents my HMD from getting disorted fbcon, and from affecting other displays console. v2: Change description from non-standard to non-desktop Reviewed-by: Keith Packard <keithp@keithp.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/gpu/drm/drm_fb_helper.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/gpu/drm/drm_fb_helper.c b/drivers/gpu/drm/drm_fb_helper.c
index 116d1f1337c7..07374008f146 100644
--- a/drivers/gpu/drm/drm_fb_helper.c
+++ b/drivers/gpu/drm/drm_fb_helper.c
@@ -2033,6 +2033,9 @@ static bool drm_connector_enabled(struct drm_connector *connector, bool strict)
{
bool enable;
+ if (connector->display_info.non_desktop)
+ return false;
+
if (strict)
enable = connector->status == connector_status_connected;
else
@@ -2052,7 +2055,8 @@ static void drm_enable_connectors(struct drm_fb_helper *fb_helper,
connector = fb_helper->connector_info[i]->connector;
enabled[i] = drm_connector_enabled(connector, true);
DRM_DEBUG_KMS("connector %d enabled? %s\n", connector->base.id,
- enabled[i] ? "yes" : "no");
+ connector->display_info.non_desktop ? "non desktop" : enabled[i] ? "yes" : "no");
+
any_enabled |= enabled[i];
}