From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id DF314C433EF for ; Fri, 26 Nov 2021 16:04:13 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id F24F96E128; Fri, 26 Nov 2021 16:04:12 +0000 (UTC) Received: from wout4-smtp.messagingengine.com (wout4-smtp.messagingengine.com [64.147.123.20]) by gabe.freedesktop.org (Postfix) with ESMTPS id 25F986E128 for ; Fri, 26 Nov 2021 16:04:12 +0000 (UTC) Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.west.internal (Postfix) with ESMTP id AAD293200F6F; Fri, 26 Nov 2021 11:04:10 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute6.internal (MEProxy); Fri, 26 Nov 2021 11:04:11 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cerno.tech; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm1; bh=WeKoRdhgN2LwHTqUKyoxBMgSKkp O+jfUxzPhmlRJtXA=; b=Fc0Rog7TzCGHn7bDhibJLPE9bhZlINhO7PzFx6X3X8e lD6xEpKpKeGkWD70KXJrUvk1qiTlDl0hfJz2AS0XrAymNyn3BfmxTI5ntr3V4uNg N5u5yQFimKfAWicilkz1RG3cvZ30/YB0f29PpA2vGQeZbf4J7V6whyg8b6jBEYXr vuU/EiTTLoG/BE5qSmjsyJYdH4kQskn7ZqTB/SYjRPf8RZjPaBG9FQjFlv1JEWkg kHdcGmJhOAmWpdNHhhIXiMf2eyt4IOubpOjDbmLrnldnlBkgkvKQ7UcYUv9v/u/X aw+nLqomEzDirY6OPwt+k2kAdGHwyf7Hk4S566PLZyw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=WeKoRd hgN2LwHTqUKyoxBMgSKkpO+jfUxzPhmlRJtXA=; b=jRDlAjUo4sci9Uyc8vxvyR PPXLk2H4aZJXv7A0tljnslBDK9rY6HssPiY6tLhA++UJERREKAgqxVatNYH34OwW tWvY0bSAFSIcZUOU7ID34DRO4FqjC8Rohve61qaJDWmXYooVU2SS9CCGtDx2CRgv FAHG7FGFq5vjMgGaV/ubiZf7cN5OfCRks+YcOHBN7XQQMmOHWIEXcaudO2fGkwas 7MCrIA7C4cooCwl9ASCz1cS15smxJQHzfDlPvzS0/aG9j0dKVzu9tLFpdL5MaSx5 qmdNAO6H2QmG3Vac/WmzeIP2dkZ1tLgScT9Sm/dpUTuZQzq3T1jFO0ywoN5cC1NA == X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvuddrhedvgdekvdcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpeffhffvuffkfhggtggujgesghdtreertddtvdenucfhrhhomhepofgrgihimhgv ucftihhprghrugcuoehmrgigihhmvgestggvrhhnohdrthgvtghhqeenucggtffrrghtth gvrhhnpeevveefffduveeitdegtefhhfetueffteefffdvheevvdehteethedvleffgfej vdenucffohhmrghinhepkhgvrhhnvghlrdhorhhgnecuvehluhhsthgvrhfuihiivgeptd enucfrrghrrghmpehmrghilhhfrhhomhepmhgrgihimhgvsegtvghrnhhordhtvggthh X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Fri, 26 Nov 2021 11:04:07 -0500 (EST) Date: Fri, 26 Nov 2021 17:04:06 +0100 From: Maxime Ripard To: Jagan Teki Subject: Re: [PATCH v5 3/7] drm: sun4i: dsi: Convert to bridge driver Message-ID: <20211126160406.5634xkgmzihngotz@houat> References: <20211122065223.88059-4-jagan@amarulasolutions.com> <20211122100712.dls4eqsu6o5gcc5k@gilmour> <20211122140457.jm7cwpp2h3fkf2nd@gilmour> <20211125141516.oymscgs3xcjqmgce@gilmour> <20211125161026.ndfygaa6c4nnst4i@gilmour> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="kvsmesxwtlt4aksb" Content-Disposition: inline In-Reply-To: X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Neil Armstrong , Robert Foss , linux-sunxi@googlegroups.com, dri-devel@lists.freedesktop.org, Chen-Yu Tsai , Laurent Pinchart , Sam Ravnborg , linux-amarula@amarulasolutions.com, linux-arm-kernel@lists.infradead.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" --kvsmesxwtlt4aksb Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Nov 25, 2021 at 09:44:14PM +0530, Jagan Teki wrote: > On Thu, Nov 25, 2021 at 9:40 PM Maxime Ripard wrote: > > > > On Thu, Nov 25, 2021 at 07:55:41PM +0530, Jagan Teki wrote: > > > Hi, > > > > > > On Thu, Nov 25, 2021 at 7:45 PM Maxime Ripard wro= te: > > > > > > > > On Wed, Nov 24, 2021 at 12:02:47AM +0530, Jagan Teki wrote: > > > > > > > > > > + dsi->panel =3D of_drm_find_panel(remote); > > > > > > > > > > + if (IS_ERR(dsi->panel)) { > > > > > > > > > > + dsi->panel =3D NULL; > > > > > > > > > > + > > > > > > > > > > + dsi->next_bridge =3D of_drm_find_bridge(r= emote); > > > > > > > > > > + if (IS_ERR(dsi->next_bridge)) { > > > > > > > > > > + dev_err(dsi->dev, "failed to find= bridge\n"); > > > > > > > > > > + return PTR_ERR(dsi->next_bridge); > > > > > > > > > > + } > > > > > > > > > > + } else { > > > > > > > > > > + dsi->next_bridge =3D NULL; > > > > > > > > > > + } > > > > > > > > > > + > > > > > > > > > > + of_node_put(remote); > > > > > > > > > > > > > > > > > > Using devm_drm_of_get_bridge would greatly simplify the d= river > > > > > > > > > > > > > > > > I'm aware of this and this would break the existing sunxi d= si binding, > > > > > > > > we are not using ports based pipeline in dsi node. Of-cours= e you have > > > > > > > > pointed the same before, please check below > > > > > > > > https://patchwork.kernel.org/project/dri-devel/patch/202103= 22140152.101709-2-jagan@amarulasolutions.com/ > > > > > > > > > > > > > > Then drm_of_find_panel_or_bridge needs to be adjusted to hand= le the DSI > > > > > > > bindings and look for a panel or bridge not only through the = OF graph, > > > > > > > but also on the child nodes > > > > > > > > > > > > Okay. I need to check this. > > > > > > > > > > devm_drm_of_get_bridge is not working with legacy binding like th= e one > > > > > used in sun6i dsi > > > > > > > > There's nothing legacy about it. > > > > > > What I'm mean legacy here with current binding used in sun6i-dsi like= this. > > > > > > &dsi { > > > vcc-dsi-supply =3D <®_dcdc1>; /* VCC-DSI */ > > > status =3D "okay"; > > > > > > panel@0 { > > > compatible =3D "bananapi,s070wv20-ct16-icn6211"; > > > reg =3D <0>; > > > reset-gpios =3D <&r_pio 0 5 GPIO_ACTIVE_HIGH>; /* > > > LCD-RST: PL5 */ > > > enable-gpios =3D <&pio 1 7 GPIO_ACTIVE_HIGH>; /* > > > LCD-PWR-EN: PB7 */ > > > backlight =3D <&backlight>; > > > }; > > > }; > > > > Yes, I know, it's the generic DSI binding. It's still not legacy. > > > > > devm_drm_of_get_bridge cannot find the device with above binding and > > > able to find the device with below binding. > > > > > > &dsi { > > > vcc-dsi-supply =3D <®_dcdc1>; /* VCC-DSI */ > > > status =3D "okay"; > > > > > > ports { > > > #address-cells =3D <1>; > > > #size-cells =3D <0>; > > > > > > dsi_out: port@0 { > > > reg =3D <0>; > > > > > > dsi_out_bridge: endpoint { > > > remote-endpoint =3D <&bridge_out_dsi>; > > > }; > > > }; > > > }; > > > > > > panel@0 { > > > compatible =3D "bananapi,s070wv20-ct16-icn6211"; > > > reg =3D <0>; > > > reset-gpios =3D <&r_pio 0 5 GPIO_ACTIVE_HIGH>; /* LCD-RS= T: PL5 */ > > > enable-gpios =3D <&pio 1 7 GPIO_ACTIVE_HIGH>; /* LCD-PWR= -EN: PB7 */ > > > backlight =3D <&backlight>; > > > > > > port { > > > bridge_out_dsi: endpoint { > > > remote-endpoint =3D <&dsi_out_bridge>; > > > }; > > > }; > > > }; > > > }; > > > > Yes, I know, and that's because ... >=20 > Okay. I will use find panel and bridge separately instead of > devm_drm_of_get_bridge in version patches. That's not been my point, at all? I mean, that whole discussion has been because you shouldn't do that. > > > > > > > > > > > https://patchwork.kernel.org/project/dri-devel/patch/202111220652= 23.88059-6-jagan@amarulasolutions.com/ > > > > > > > > > > dsi->next_bridge =3D devm_drm_of_get_bridge(dsi->dev, dsi->dev->o= f_node, 0, 0); > > > > > if (IS_ERR(dsi->next_bridge)) > > > > > return PTR_ERR(dsi->next_bridge); > > > > > > > > > > It is only working if we have ports on the pipeline, something li= ke this > > > > > https://patchwork.kernel.org/project/dri-devel/patch/202102141941= 02.126146-8-jagan@amarulasolutions.com/ > > > > > > > > > > Please have a look and let me know if I miss anything? > > > > > > > > Yes, you're missing the answer you quoted earlier: > > > > > > Yes, I'm trying to resolve the comment one after another. Will get ba= ck. > > > > ... You've ignored that comment. >=20 > Not understand which comment you mean. There are few about bridge > conversion details, I will send my comments. The one that got quoted there and you removed. For reference: > Then drm_of_find_panel_or_bridge needs to be adjusted to handle the DSI > bindings and look for a panel or bridge not only through the OF graph, > but also on the child nodes devm_drm_of_get_bridge uses drm_of_find_panel_or_bridge under the hood, so of course it won't find it if drm_of_find_panel_or_bridge doesn't. You need to modify drm_of_find_panel_or_bridge to also look for child devices and see if there's a panel or bridge registered for that child node. Then devm_drm_of_get_bridge will work as you intend it to. Maxime --kvsmesxwtlt4aksb Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCYaEFdgAKCRDj7w1vZxhR xfhtAQClCB5fjDKDhwBYdSS4w0ucj1H0ykj29MaN6OGnw35/iwEA76u4JrTkH1Lz MZJBykVEjk07zHQ8MlhpBvzbbpaD2QI= =M8B4 -----END PGP SIGNATURE----- --kvsmesxwtlt4aksb-- From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 30F6FC433EF for ; Fri, 26 Nov 2021 16:05:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:Content-Type: List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: In-Reply-To:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date: Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date :Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=CQVUcWkeSl6ZGoWEKOJSp1xJLW1dcIZOHorGkgSdGWY=; b=eHitavtaGZ6h1a6gbRZmhvJFrQ 3TuJrctunfSLBsNAlSvsfN/NxOD4gRqMaYLrGWvPqH05R/m3+SNrAtbf7Sfj4bx+Or93INpILh/CQ UyeJecSeO6PLtc3S1cF2eBnSRXKVDB5RHNWdGFpT7r2e7NrJLUzCyfhzoY+lukfEW4nncKBixfP9G XdqWp0c2h3UeSmytR3RGzNGOAULgnVlxt3Deu36FeA/+4+xNQWgYI90V8tB57ueeICgscuZFK2OfU FgWNgZ5Z8TbFOSn8qZcrgeHAHDtBKsziY+z3BPoqoPmqmk4iPNrVHCYZ/ff+Cdjbpc/Eq3hM9epNz ukX98NWA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mqdhw-00B45g-4s; Fri, 26 Nov 2021 16:04:16 +0000 Received: from wout4-smtp.messagingengine.com ([64.147.123.20]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mqdhs-00B450-8c for linux-arm-kernel@lists.infradead.org; Fri, 26 Nov 2021 16:04:14 +0000 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.west.internal (Postfix) with ESMTP id AAD293200F6F; Fri, 26 Nov 2021 11:04:10 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute6.internal (MEProxy); Fri, 26 Nov 2021 11:04:11 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cerno.tech; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm1; bh=WeKoRdhgN2LwHTqUKyoxBMgSKkp O+jfUxzPhmlRJtXA=; b=Fc0Rog7TzCGHn7bDhibJLPE9bhZlINhO7PzFx6X3X8e lD6xEpKpKeGkWD70KXJrUvk1qiTlDl0hfJz2AS0XrAymNyn3BfmxTI5ntr3V4uNg N5u5yQFimKfAWicilkz1RG3cvZ30/YB0f29PpA2vGQeZbf4J7V6whyg8b6jBEYXr vuU/EiTTLoG/BE5qSmjsyJYdH4kQskn7ZqTB/SYjRPf8RZjPaBG9FQjFlv1JEWkg kHdcGmJhOAmWpdNHhhIXiMf2eyt4IOubpOjDbmLrnldnlBkgkvKQ7UcYUv9v/u/X aw+nLqomEzDirY6OPwt+k2kAdGHwyf7Hk4S566PLZyw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=WeKoRd hgN2LwHTqUKyoxBMgSKkpO+jfUxzPhmlRJtXA=; b=jRDlAjUo4sci9Uyc8vxvyR PPXLk2H4aZJXv7A0tljnslBDK9rY6HssPiY6tLhA++UJERREKAgqxVatNYH34OwW tWvY0bSAFSIcZUOU7ID34DRO4FqjC8Rohve61qaJDWmXYooVU2SS9CCGtDx2CRgv FAHG7FGFq5vjMgGaV/ubiZf7cN5OfCRks+YcOHBN7XQQMmOHWIEXcaudO2fGkwas 7MCrIA7C4cooCwl9ASCz1cS15smxJQHzfDlPvzS0/aG9j0dKVzu9tLFpdL5MaSx5 qmdNAO6H2QmG3Vac/WmzeIP2dkZ1tLgScT9Sm/dpUTuZQzq3T1jFO0ywoN5cC1NA == X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvuddrhedvgdekvdcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpeffhffvuffkfhggtggujgesghdtreertddtvdenucfhrhhomhepofgrgihimhgv ucftihhprghrugcuoehmrgigihhmvgestggvrhhnohdrthgvtghhqeenucggtffrrghtth gvrhhnpeevveefffduveeitdegtefhhfetueffteefffdvheevvdehteethedvleffgfej vdenucffohhmrghinhepkhgvrhhnvghlrdhorhhgnecuvehluhhsthgvrhfuihiivgeptd enucfrrghrrghmpehmrghilhhfrhhomhepmhgrgihimhgvsegtvghrnhhordhtvggthh X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Fri, 26 Nov 2021 11:04:07 -0500 (EST) Date: Fri, 26 Nov 2021 17:04:06 +0100 From: Maxime Ripard To: Jagan Teki Cc: Chen-Yu Tsai , Laurent Pinchart , Neil Armstrong , Robert Foss , Sam Ravnborg , dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@googlegroups.com, linux-amarula@amarulasolutions.com Subject: Re: [PATCH v5 3/7] drm: sun4i: dsi: Convert to bridge driver Message-ID: <20211126160406.5634xkgmzihngotz@houat> References: <20211122065223.88059-4-jagan@amarulasolutions.com> <20211122100712.dls4eqsu6o5gcc5k@gilmour> <20211122140457.jm7cwpp2h3fkf2nd@gilmour> <20211125141516.oymscgs3xcjqmgce@gilmour> <20211125161026.ndfygaa6c4nnst4i@gilmour> MIME-Version: 1.0 In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211126_080412_375569_5C541461 X-CRM114-Status: GOOD ( 34.80 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: multipart/mixed; boundary="===============6956943706693697185==" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org --===============6956943706693697185== Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="kvsmesxwtlt4aksb" Content-Disposition: inline --kvsmesxwtlt4aksb Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Nov 25, 2021 at 09:44:14PM +0530, Jagan Teki wrote: > On Thu, Nov 25, 2021 at 9:40 PM Maxime Ripard wrote: > > > > On Thu, Nov 25, 2021 at 07:55:41PM +0530, Jagan Teki wrote: > > > Hi, > > > > > > On Thu, Nov 25, 2021 at 7:45 PM Maxime Ripard wro= te: > > > > > > > > On Wed, Nov 24, 2021 at 12:02:47AM +0530, Jagan Teki wrote: > > > > > > > > > > + dsi->panel =3D of_drm_find_panel(remote); > > > > > > > > > > + if (IS_ERR(dsi->panel)) { > > > > > > > > > > + dsi->panel =3D NULL; > > > > > > > > > > + > > > > > > > > > > + dsi->next_bridge =3D of_drm_find_bridge(r= emote); > > > > > > > > > > + if (IS_ERR(dsi->next_bridge)) { > > > > > > > > > > + dev_err(dsi->dev, "failed to find= bridge\n"); > > > > > > > > > > + return PTR_ERR(dsi->next_bridge); > > > > > > > > > > + } > > > > > > > > > > + } else { > > > > > > > > > > + dsi->next_bridge =3D NULL; > > > > > > > > > > + } > > > > > > > > > > + > > > > > > > > > > + of_node_put(remote); > > > > > > > > > > > > > > > > > > Using devm_drm_of_get_bridge would greatly simplify the d= river > > > > > > > > > > > > > > > > I'm aware of this and this would break the existing sunxi d= si binding, > > > > > > > > we are not using ports based pipeline in dsi node. Of-cours= e you have > > > > > > > > pointed the same before, please check below > > > > > > > > https://patchwork.kernel.org/project/dri-devel/patch/202103= 22140152.101709-2-jagan@amarulasolutions.com/ > > > > > > > > > > > > > > Then drm_of_find_panel_or_bridge needs to be adjusted to hand= le the DSI > > > > > > > bindings and look for a panel or bridge not only through the = OF graph, > > > > > > > but also on the child nodes > > > > > > > > > > > > Okay. I need to check this. > > > > > > > > > > devm_drm_of_get_bridge is not working with legacy binding like th= e one > > > > > used in sun6i dsi > > > > > > > > There's nothing legacy about it. > > > > > > What I'm mean legacy here with current binding used in sun6i-dsi like= this. > > > > > > &dsi { > > > vcc-dsi-supply =3D <®_dcdc1>; /* VCC-DSI */ > > > status =3D "okay"; > > > > > > panel@0 { > > > compatible =3D "bananapi,s070wv20-ct16-icn6211"; > > > reg =3D <0>; > > > reset-gpios =3D <&r_pio 0 5 GPIO_ACTIVE_HIGH>; /* > > > LCD-RST: PL5 */ > > > enable-gpios =3D <&pio 1 7 GPIO_ACTIVE_HIGH>; /* > > > LCD-PWR-EN: PB7 */ > > > backlight =3D <&backlight>; > > > }; > > > }; > > > > Yes, I know, it's the generic DSI binding. It's still not legacy. > > > > > devm_drm_of_get_bridge cannot find the device with above binding and > > > able to find the device with below binding. > > > > > > &dsi { > > > vcc-dsi-supply =3D <®_dcdc1>; /* VCC-DSI */ > > > status =3D "okay"; > > > > > > ports { > > > #address-cells =3D <1>; > > > #size-cells =3D <0>; > > > > > > dsi_out: port@0 { > > > reg =3D <0>; > > > > > > dsi_out_bridge: endpoint { > > > remote-endpoint =3D <&bridge_out_dsi>; > > > }; > > > }; > > > }; > > > > > > panel@0 { > > > compatible =3D "bananapi,s070wv20-ct16-icn6211"; > > > reg =3D <0>; > > > reset-gpios =3D <&r_pio 0 5 GPIO_ACTIVE_HIGH>; /* LCD-RS= T: PL5 */ > > > enable-gpios =3D <&pio 1 7 GPIO_ACTIVE_HIGH>; /* LCD-PWR= -EN: PB7 */ > > > backlight =3D <&backlight>; > > > > > > port { > > > bridge_out_dsi: endpoint { > > > remote-endpoint =3D <&dsi_out_bridge>; > > > }; > > > }; > > > }; > > > }; > > > > Yes, I know, and that's because ... >=20 > Okay. I will use find panel and bridge separately instead of > devm_drm_of_get_bridge in version patches. That's not been my point, at all? I mean, that whole discussion has been because you shouldn't do that. > > > > > > > > > > > https://patchwork.kernel.org/project/dri-devel/patch/202111220652= 23.88059-6-jagan@amarulasolutions.com/ > > > > > > > > > > dsi->next_bridge =3D devm_drm_of_get_bridge(dsi->dev, dsi->dev->o= f_node, 0, 0); > > > > > if (IS_ERR(dsi->next_bridge)) > > > > > return PTR_ERR(dsi->next_bridge); > > > > > > > > > > It is only working if we have ports on the pipeline, something li= ke this > > > > > https://patchwork.kernel.org/project/dri-devel/patch/202102141941= 02.126146-8-jagan@amarulasolutions.com/ > > > > > > > > > > Please have a look and let me know if I miss anything? > > > > > > > > Yes, you're missing the answer you quoted earlier: > > > > > > Yes, I'm trying to resolve the comment one after another. Will get ba= ck. > > > > ... You've ignored that comment. >=20 > Not understand which comment you mean. There are few about bridge > conversion details, I will send my comments. The one that got quoted there and you removed. For reference: > Then drm_of_find_panel_or_bridge needs to be adjusted to handle the DSI > bindings and look for a panel or bridge not only through the OF graph, > but also on the child nodes devm_drm_of_get_bridge uses drm_of_find_panel_or_bridge under the hood, so of course it won't find it if drm_of_find_panel_or_bridge doesn't. You need to modify drm_of_find_panel_or_bridge to also look for child devices and see if there's a panel or bridge registered for that child node. Then devm_drm_of_get_bridge will work as you intend it to. Maxime --kvsmesxwtlt4aksb Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCYaEFdgAKCRDj7w1vZxhR xfhtAQClCB5fjDKDhwBYdSS4w0ucj1H0ykj29MaN6OGnw35/iwEA76u4JrTkH1Lz MZJBykVEjk07zHQ8MlhpBvzbbpaD2QI= =M8B4 -----END PGP SIGNATURE----- --kvsmesxwtlt4aksb-- --===============6956943706693697185== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel --===============6956943706693697185==--