Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp4192160ybl; Mon, 9 Dec 2019 06:57:23 -0800 (PST) X-Google-Smtp-Source: APXvYqxJUP9sbIPc8Q09XBQhsjbhQTOgprPOIurhcL0KTwL1yV7RQTJT+u838rkijmRrNNP3PDbA X-Received: by 2002:aca:ecd0:: with SMTP id k199mr25196821oih.158.1575903443477; Mon, 09 Dec 2019 06:57:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1575903443; cv=none; d=google.com; s=arc-20160816; b=SRxQtQ+2R4Vi02hu3GwvjoojuZlXCndiQoNwtcmnE23aD7/EuGdkPuEU+ItXivBpyj VtNQ3v5bW9Cb9ccWv1LEUBAj4j/eQxOe+lnwhGBedFTMPv9tGpQ5aOqlg45qSNJPjVpv SMXmvlrVpHgt52iexvmsFBI+e2v42EV+bzMnmsssfjE4+3iA/zvyP6MOgkRf5bscpYjI qU2qLAGdK8UYTBjQg440IOrkVaLcA06hrsw4cxCIkx5BzGprCv2AlmGY2Blyy6H7MBR6 KZt+gzTPR+CiACC0OPeBWXIVgFmx3WDMnDMUrYJ27JmRXJGqddaXCCVSBuS0VL8Y63Dq v4Cg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=/tYW5XRRkq94dA93JGJPgxsI/V1Ydlhrx6EMq+5sil0=; b=RztkqD40/jclVDlTp055FeWSxl4DjfdizoQt9JsZ31bTqGOdQmkgiZel2oO+OmyiEJ cSeraGZNrzGOJi5EoPiK4pe6FUz/1yBO2nsQZ+QA1qbycg4ukj5g+44qUorpepBjlBk9 naZ0vbiLQesjEIPOw7ymuIsrl8s9XgwiwtPddSo/sBgu885vp4TlhbTqq73vbkf6C4cY W+qw801R4mzaAYo0oFla5hNxuIFzyU/xA14Gv653IuDbLZ4HaQJ3Pmfalfokmfqzuk5a XSAsNyoeoaCF7SfcTR0JhoCa6PYGX86AJVbThaysW9LCjxS+sgj2tcUniuV4yvJrDxDW M1qg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=KLmhXjwx; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p14si12556396ota.71.2019.12.09.06.57.12; Mon, 09 Dec 2019 06:57:23 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=KLmhXjwx; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726823AbfLIO4C (ORCPT + 99 others); Mon, 9 Dec 2019 09:56:02 -0500 Received: from perceval.ideasonboard.com ([213.167.242.64]:36732 "EHLO perceval.ideasonboard.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726310AbfLIO4C (ORCPT ); Mon, 9 Dec 2019 09:56:02 -0500 Received: from pendragon.ideasonboard.com (81-175-216-236.bb.dnainternet.fi [81.175.216.236]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id F1DB1B2C; Mon, 9 Dec 2019 15:55:58 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1575903359; bh=vhHx1PjaeLJMGX9Xm/0FmdneX5UOPsaDKk1edME3V0E=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=KLmhXjwxkqST47lNHsRUzGQqrDVHkl3c+KEPg1zP3Ttm5HKzRD51bsx7fPcEoof5N JkRhxfzbfdZyjwrPFyime4fUdMN//fdWye6bRsV+F6FR9CxaH6Yjbms1M9L5ujuLuG xFBjXkFEh0fGG39k1yujz9Qv7wmaOuWNTRh9wa3Q= Date: Mon, 9 Dec 2019 16:55:52 +0200 From: Laurent Pinchart To: Hsin-Yi Wang Cc: dri-devel@lists.freedesktop.org, David Airlie , Daniel Vetter , Rob Herring , Mark Rutland , Nicolas Boichat , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Andrzej Hajda , Neil Armstrong , Jonas Karlman , Jernej Skrabec , Archit Taneja , p.zabel@pengutronix.de, Enric Balletbo i Serra , Matthias Brugger , Russell King Subject: Re: [PATCH RESEND 3/4] dt-bindings: drm/bridge: analogix-anx78xx: support bypass GPIO Message-ID: <20191209145552.GD12841@pendragon.ideasonboard.com> References: <20191209145016.227784-1-hsinyi@chromium.org> <20191209145016.227784-4-hsinyi@chromium.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20191209145016.227784-4-hsinyi@chromium.org> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Hsin-Yi, Thank you for the patch. On Mon, Dec 09, 2019 at 10:50:15PM +0800, Hsin-Yi Wang wrote: > Support optional feature: bypass GPIO. > > Some SoC (eg. mt8173) have a hardware mux that connects to 2 ports: > anx7688 and hdmi. When the GPIO is active, the bridge is bypassed. This doesn't look like the right place to fix this, as the mux is unrelated to the bridge. You would have to duplicate this logic in every bridge driver otherwise. Could you describe the hardware topology in a bit more details ? I can then try to advise on how to best support it. > Signed-off-by: Hsin-Yi Wang > --- > .../bindings/display/bridge/anx7688.txt | 40 ++++++++++++++++++- > 1 file changed, 39 insertions(+), 1 deletion(-) > > diff --git a/Documentation/devicetree/bindings/display/bridge/anx7688.txt b/Documentation/devicetree/bindings/display/bridge/anx7688.txt > index 78b55bdb18f7..44185dcac839 100644 > --- a/Documentation/devicetree/bindings/display/bridge/anx7688.txt > +++ b/Documentation/devicetree/bindings/display/bridge/anx7688.txt > @@ -15,10 +15,13 @@ Required properties: > Optional properties: > > - Video port for HDMI input, using the DT bindings defined in [1]. > + - bypass-gpios : External GPIO. If this GPIO is active, we assume > + the bridge is bypassed (e.g. by a mux). > + - pinctrl-0, pinctrl-names: the pincontrol settings to configure bypass GPIO. > > [1]: Documentation/devicetree/bindings/media/video-interfaces.txt > > -Example: > +Example 1: > > anx7688: anx7688@2c { > compatible = "analogix,anx7688"; > @@ -30,3 +33,38 @@ Example: > }; > }; > }; > + > +Example 2: > + > + anx7688: anx7688@2c { > + compatible = "analogix,anx7688"; > + status = "okay"; > + reg = <0x2c>; > + ddc-i2c-bus = <&hdmiddc0>; > + > + bypass-gpios = <&pio 36 GPIO_ACTIVE_HIGH>; > + pinctrl-names = "default"; > + pinctrl-0 = <&hdmi_mux_pins>; > + > + ports { > + #address-cells = <1>; > + #size-cells = <0>; > + > + port@0 { /* input */ > + reg = <0>; > + > + anx7688_in: endpoint { > + remote-endpoint = <&hdmi_out_anx>; > + }; > + }; > + > + port@1 { /* output */ > + reg = <1>; > + > + anx7688_out: endpoint { > + remote-endpoint = <&hdmi_connector_in>; > + }; > + }; > + }; > + }; > + -- Regards, Laurent Pinchart