From patchwork Tue May 9 07:16:27 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 9717123 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id BBF5960364 for ; Tue, 9 May 2017 07:16:59 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id ACD242621B for ; Tue, 9 May 2017 07:16:59 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id A01A328307; Tue, 9 May 2017 07:16:59 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 39C2B2621B for ; Tue, 9 May 2017 07:16:58 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id B202A6E03D; Tue, 9 May 2017 07:16:55 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from lelnx194.ext.ti.com (lelnx194.ext.ti.com [198.47.27.80]) by gabe.freedesktop.org (Postfix) with ESMTPS id 7EEEB6E03D for ; Tue, 9 May 2017 07:16:54 +0000 (UTC) Received: from dflxv15.itg.ti.com ([128.247.5.124]) by lelnx194.ext.ti.com (8.15.1/8.15.1) with ESMTP id v497GpDZ023774; Tue, 9 May 2017 02:16:51 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ti.com; s=ti-com-17Q1; t=1494314211; bh=f7ykfxArUK6fsTSlwR2VvXQAmNKmX7FT7h/LpSC9qUQ=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=W9KVkS5i5xGSAMTsNdywBccO3uVtCmdiddMMZojtiprEZ6qfpl4GIGdXO+Nuw9UYR vOlBjbJvLK0qDVq9/k2JPv1Yg6eF128ZEfaGH5GEpTQkTqizz7f3U9Sz4uY+dSx6Xs QETWewX9lZdcSJlJA/TjRtI44xZCJ80gcyy+VI2A= Received: from DFLE73.ent.ti.com (dfle73.ent.ti.com [128.247.5.110]) by dflxv15.itg.ti.com (8.14.3/8.13.8) with ESMTP id v497GpC3011880; Tue, 9 May 2017 02:16:51 -0500 Received: from dlep32.itg.ti.com (157.170.170.100) by DFLE73.ent.ti.com (128.247.5.110) with Microsoft SMTP Server id 14.3.294.0; Tue, 9 May 2017 02:16:50 -0500 Received: from deskari.ti.com (ileax41-snat.itg.ti.com [10.172.224.153]) by dlep32.itg.ti.com (8.14.3/8.13.8) with ESMTP id v497GnJI006347; Tue, 9 May 2017 02:16:50 -0500 From: Tomi Valkeinen To: , Laurent Pinchart Subject: [PATCH 1/6 v2] drm/omap: add new connector types Date: Tue, 9 May 2017 10:16:27 +0300 Message-ID: <1494314187-12816-1-git-send-email-tomi.valkeinen@ti.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1493288874-26654-2-git-send-email-tomi.valkeinen@ti.com> References: <1493288874-26654-2-git-send-email-tomi.valkeinen@ti.com> MIME-Version: 1.0 Cc: Tomi Valkeinen , Jyri Sarha 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: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP We have been using DRM_MODE_CONNECTOR_Unknown for many of our outputs because there has not been a proper connector type for them. We now have connector type for DPI so let's take it into use. At the same time, add better connector types for the remaining outputs too. This patch sets the following outputs to use the following connector types: DPI -> DPI DBI -> DPI (MIPI DBI is very similar to DPI at the bus level) SDI -> LVDS (SDI, TI Flatlink 3G, is a type of LVDS) VENC -> SVIDEO (it could also be composite, but we don't have that information here, so svideo should be quite good match) Signed-off-by: Tomi Valkeinen --- drivers/gpu/drm/omapdrm/omap_drv.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/drivers/gpu/drm/omapdrm/omap_drv.c b/drivers/gpu/drm/omapdrm/omap_drv.c index e1f47f0b3ccf..16c537837742 100644 --- a/drivers/gpu/drm/omapdrm/omap_drv.c +++ b/drivers/gpu/drm/omapdrm/omap_drv.c @@ -214,6 +214,19 @@ static int get_connector_type(struct omap_dss_device *dssdev) return DRM_MODE_CONNECTOR_DVID; case OMAP_DISPLAY_TYPE_DSI: return DRM_MODE_CONNECTOR_DSI; + case OMAP_DISPLAY_TYPE_DPI: + case OMAP_DISPLAY_TYPE_DBI: + return DRM_MODE_CONNECTOR_DPI; + case OMAP_DISPLAY_TYPE_VENC: + if (of_device_is_compatible(dssdev->dev->of_node, + "omapdss,svideo-connector")) + return DRM_MODE_CONNECTOR_SVIDEO; + if (of_device_is_compatible(dssdev->dev->of_node, + "omapdss,composite-video-connector")) + return DRM_MODE_CONNECTOR_Composite; + return DRM_MODE_CONNECTOR_Unknown; + case OMAP_DISPLAY_TYPE_SDI: + return DRM_MODE_CONNECTOR_LVDS; default: return DRM_MODE_CONNECTOR_Unknown; }