From patchwork Tue May 28 08:27:23 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 10964123 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id AF2EB1395 for ; Tue, 28 May 2019 08:28:11 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A1A43286BD for ; Tue, 28 May 2019 08:28:11 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 96206286D1; Tue, 28 May 2019 08:28:11 +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=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED 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 4233F286BD for ; Tue, 28 May 2019 08:28:11 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 3C73989C1F; Tue, 28 May 2019 08:28:08 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from fllv0015.ext.ti.com (fllv0015.ext.ti.com [198.47.19.141]) by gabe.freedesktop.org (Postfix) with ESMTPS id D3AE189C1F for ; Tue, 28 May 2019 08:28:06 +0000 (UTC) Received: from fllv0035.itg.ti.com ([10.64.41.0]) by fllv0015.ext.ti.com (8.15.2/8.15.2) with ESMTP id x4S8S3cV125063; Tue, 28 May 2019 03:28:03 -0500 Received: from DLEE107.ent.ti.com (dlee107.ent.ti.com [157.170.170.37]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTPS id x4S8S3kJ007830 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Tue, 28 May 2019 03:28:03 -0500 Received: from DLEE100.ent.ti.com (157.170.170.30) by DLEE107.ent.ti.com (157.170.170.37) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1713.5; Tue, 28 May 2019 03:28:01 -0500 Received: from lelv0327.itg.ti.com (10.180.67.183) by DLEE100.ent.ti.com (157.170.170.30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1713.5 via Frontend Transport; Tue, 28 May 2019 03:28:01 -0500 Received: from deskari.ti.com (ileax41-snat.itg.ti.com [10.172.224.153]) by lelv0327.itg.ti.com (8.15.2/8.15.2) with ESMTP id x4S8RxuU125039; Tue, 28 May 2019 03:27:59 -0500 From: Tomi Valkeinen To: , Andrzej Hajda , Laurent Pinchart , Lucas Stach , Andrey Gusakov , Philipp Zabel , Andrey Smirnov , Peter Ujfalusi , Jyri Sarha , Benoit Parrot Subject: [PATCHv4 00/24] drm/bridge: tc358767: DP support Date: Tue, 28 May 2019 11:27:23 +0300 Message-ID: <20190528082747.3631-1-tomi.valkeinen@ti.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1559032083; bh=R5sp09OHOWO5+KLSDKwjP3nxefsamy7OqDbkSedgpJE=; h=From:To:CC:Subject:Date; b=c3P45z3ZMmqsDb49UkA1gHuoVrZqn7xeNMVhrvBDfcmNckaRCXH4J6FC2EncF4Flc 9m0ELolkiVqgoN9yIlzJpOnKY508veZNC8897w0o7CQ/9HDgg2kwfY1DV7XU19m9KP ki+hAwHkjbeKMl5s99eXKFLH+ff07MwIxb8BB/Xs= X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Tomi Valkeinen Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP Hi, tc358767 bridge was originally implemented for eDP use with an embedded panel. I've been working to add DP and HPD support, and this series is the result. I did have a lot of issues with link training, but with these, it's been working reliably with my devices. Changes in v2 * Drop "implement naive HPD handling", and implement HPD interrupt handling. Changes in v3 * Various small comment, description and formatting changes * 'hpd-num' DT property renamed to 'toshiba,hpd-pin' * Check DP0CTL == 0 at the beginning of tc_main_link_enable * Disable only the video stream in tc_stream_disable() * Fix tc_connector_detect for eDP panels Changes in v4 * Add "read display_props in get_modes()" * Remove the tc_get_display_props call from detect callback * Fix the DP0CTL check in tc_main_link_enable. Only check for DP_EN bit, as we can have other bits set (e.g. after reset VID_MN_GEN is set) * Added some reviewed-bys Tomi Tomi Valkeinen (24): drm/bridge: tc358767: fix tc_aux_get_status error handling drm/bridge: tc358767: reset voltage-swing & pre-emphasis drm/bridge: tc358767: fix ansi 8b10b use drm/bridge: tc358767: cleanup spread & scrambler_dis drm/bridge: tc358767: remove unused swing & preemp drm/bridge: tc358767: cleanup aux_link_setup drm/bridge: tc358767: move video stream setup to tc_main_link_stream drm/bridge: tc358767: split stream enable/disable drm/bridge: tc358767: move PXL PLL enable/disable to stream enable/disable drm/bridge: tc358767: add link disable function drm/bridge: tc358767: disable only video stream in tc_stream_disable drm/bridge: tc358767: ensure DP is disabled before LT drm/bridge: tc358767: remove unnecessary msleep drm/bridge: tc358767: use more reliable seq when finishing LT drm/bridge: tc358767: cleanup LT result check drm/bridge: tc358767: clean-up link training drm/bridge: tc358767: remove check for video mode in link enable drm/bridge: tc358767: use bridge mode_valid drm/bridge: tc358767: remove tc_connector_best_encoder drm/bridge: tc358767: copy the mode data, instead of storing the pointer drm/bridge: tc358767: read display_props in get_modes() drm/bridge: tc358767: add GPIO & interrupt registers drm/bridge: tc358767: add IRQ and HPD support dt-bindings: tc358767: add HPD support .../display/bridge/toshiba,tc358767.txt | 1 + drivers/gpu/drm/bridge/tc358767.c | 593 +++++++++++------- 2 files changed, 382 insertions(+), 212 deletions(-) --- Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki