From patchwork Tue Nov 4 01:51:45 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Hurley X-Patchwork-Id: 5221781 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 94D579F295 for ; Tue, 4 Nov 2014 01:52:23 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id CF31620160 for ; Tue, 4 Nov 2014 01:52:22 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 94DF92015E for ; Tue, 4 Nov 2014 01:52:21 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 4933B6E216; Mon, 3 Nov 2014 17:52:18 -0800 (PST) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from n23.mail01.mtsvc.net (mailout32.mail01.mtsvc.net [216.70.64.70]) by gabe.freedesktop.org (Postfix) with ESMTP id 2A09A6E216 for ; Mon, 3 Nov 2014 17:52:17 -0800 (PST) Received: from h96-61-95-138.cntcnh.dsl.dynamic.tds.net ([96.61.95.138]:53851 helo=thor.lan) by n23.mail01.mtsvc.net with esmtpsa (UNKNOWN:AES128-SHA256:128) (Exim 4.72) (envelope-from ) id 1XlTI7-00052b-Ld; Mon, 03 Nov 2014 20:52:15 -0500 From: Peter Hurley To: David Airlie Subject: [PATCH] drm: Fix DRM_FORCE_ON_DIGITAL use Date: Mon, 3 Nov 2014 20:51:45 -0500 Message-Id: <1415065905-8342-1-git-send-email-peter@hurleysoftware.com> X-Mailer: git-send-email 2.1.1 X-Authenticated-User: 990527 peter@hurleysoftware.com X-MT-ID: 8FA290C2A27252AACF65DBC4A42F3CE3735FB2A4 Cc: Peter Hurley , dri-devel@lists.freedesktop.org X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Spam-Status: No, score=-4.8 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP A connector may be forced on from the command line via video= command line setting. The digital output of dual-mode connectors can also be specifically selected and forced on; eg., 'video=DVI-I-2:D'. However, in this case, the connector->status will be mistakenly set to connector_status_disconnected, and the connector will not be mode set. Fix the connector->status when connector->force is DRM_FORCE_ON_DIGITAL. Signed-off-by: Peter Hurley --- drivers/gpu/drm/drm_probe_helper.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/drm_probe_helper.c b/drivers/gpu/drm/drm_probe_helper.c index 6857e9a..7483a47 100644 --- a/drivers/gpu/drm/drm_probe_helper.c +++ b/drivers/gpu/drm/drm_probe_helper.c @@ -118,7 +118,8 @@ static int drm_helper_probe_single_connector_modes_merge_bits(struct drm_connect mode->status = MODE_UNVERIFIED; if (connector->force) { - if (connector->force == DRM_FORCE_ON) + if (connector->force == DRM_FORCE_ON || + connector->force == DRM_FORCE_ON_DIGITAL) connector->status = connector_status_connected; else connector->status = connector_status_disconnected;