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 X-Spam-Level: X-Spam-Status: No, score=-14.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4D267C433E2 for ; Wed, 24 Mar 2021 09:58:26 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id BA150619EC for ; Wed, 24 Mar 2021 09:58:25 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org BA150619EC Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ideasonboard.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding :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-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=rcqQE5q5LDGL4Hhp7pGO7n4zZfGsOJFm52LzSGNnr/o=; b=JcHAxxcQ5Jwk8e9D6KG2z2goy 132dG49zSyS1SwUXjbuOlhtj3xe7qYdfkQkqLpANXgCLb2Pp42XpTkdipwC+hGrnk9QVzlcJrnfDd RKKdYMysL1TPuZz+bO46dX3908EWI7hyFRJol//eqwUHiG8bzlTX9JPI9yGf2WkQZc6kECRFiSgp4 +qVPgp8DsPlS4GL30LSvOh2REMzLYSASaGrNx1aarx8HkeasKPTYYUYaLuWSyJtCR324dahN3GBq2 8GuiRYkEe2aEK8RKKgMS1UuChBCjIqKIlHiDmEuViTinmWwLLhrOJqPGwuZXBTtPBmOHy2QFrUJF5 YRg9I29fA==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lP0FU-00GmfN-1c; Wed, 24 Mar 2021 09:56:24 +0000 Received: from perceval.ideasonboard.com ([2001:4b98:dc2:55:216:3eff:fef7:d647]) by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lP0FP-00GmeU-CD for linux-arm-kernel@lists.infradead.org; Wed, 24 Mar 2021 09:56:21 +0000 Received: from pendragon.ideasonboard.com (62-78-145-57.bb.dnainternet.fi [62.78.145.57]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 1E6B1883; Wed, 24 Mar 2021 10:56:18 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1616579778; bh=MF17FmOqoyOW932sJKCAjoaWTSypZjBZUltL1AENlzI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=eOZKwX2MyS2Gii8BQt2ycAY0Kt0pZDaGcZegzLv8KwWBV3kxzW6UmRFm/z3n4VyGa pxuXWya/BIBWb6oE7M/tCriPiyX1QGT8UOfRPHKBja7UuCi5Y7Qj3/QDTbopUYXkK2 gQ20dCl/DAJpkN/vaRg142NHnwBiedijx9X3AvA8= Date: Wed, 24 Mar 2021 11:55:35 +0200 From: Laurent Pinchart To: Jagan Teki Cc: Samuel Holland , Maxime Ripard , Chen-Yu Tsai , Jernej Skrabec , dri-devel , linux-arm-kernel , linux-kernel , linux-amarula , linux-sunxi Subject: Re: [PATCH v4 1/4] drm: sun4i: dsi: Use drm_of_find_panel_or_bridge Message-ID: References: <20210322140152.101709-1-jagan@amarulasolutions.com> <20210322140152.101709-2-jagan@amarulasolutions.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210324_095619_504558_F5169785 X-CRM114-Status: GOOD ( 35.81 ) 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: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi Jagan, On Wed, Mar 24, 2021 at 03:19:10PM +0530, Jagan Teki wrote: > On Wed, Mar 24, 2021 at 3:09 PM Laurent Pinchart wrote: > > On Wed, Mar 24, 2021 at 02:44:57PM +0530, Jagan Teki wrote: > > > On Wed, Mar 24, 2021 at 8:18 AM Samuel Holland wrote: > > > > On 3/23/21 5:53 PM, Laurent Pinchart wrote: > > > > > On Mon, Mar 22, 2021 at 07:31:49PM +0530, Jagan Teki wrote: > > > > >> Replace of_drm_find_panel with drm_of_find_panel_or_bridge > > > > >> for finding panel, this indeed help to find the bridge if > > > > >> bridge support added. > > > > >> > > > > >> Added NULL in bridge argument, same will replace with bridge > > > > >> parameter once bridge supported. > > > > >> > > > > >> Signed-off-by: Jagan Teki > > > > > > > > > > Looks good, there should be no functional change. > > > > > > > > Actually this breaks all existing users of this driver, see below. > > > > > > > > > Reviewed-by: Laurent Pinchart > > > > > > > > > >> --- > > > > >> Changes for v4, v3: > > > > >> - none > > > > >> > > > > >> drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c | 11 ++++++++--- > > > > >> 1 file changed, 8 insertions(+), 3 deletions(-) > > > > >> > > > > >> diff --git a/drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c b/drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c > > > > >> index 4f5efcace68e..2e9e7b2d4145 100644 > > > > >> --- a/drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c > > > > >> +++ b/drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c > > > > >> @@ -21,6 +21,7 @@ > > > > >> > > > > >> #include > > > > >> #include > > > > >> +#include > > > > >> #include > > > > >> #include > > > > >> #include > > > > >> @@ -963,10 +964,14 @@ static int sun6i_dsi_attach(struct mipi_dsi_host *host, > > > > >> struct mipi_dsi_device *device) > > > > >> { > > > > >> struct sun6i_dsi *dsi = host_to_sun6i_dsi(host); > > > > >> - struct drm_panel *panel = of_drm_find_panel(device->dev.of_node); > > > > > > > > This is using the OF node of the DSI device, which is a direct child of > > > > the DSI host's OF node. There is no OF graph involved. > > > > > > > > >> + struct drm_panel *panel; > > > > >> + int ret; > > > > >> + > > > > >> + ret = drm_of_find_panel_or_bridge(dsi->dev->of_node, 0, 0, > > > > >> + &panel, NULL); > > > > > > > > However, this function expects to find the panel using OF graph. This > > > > does not work with existing device trees (PinePhone, PineTab) which do > > > > not use OF graph to connect the panel. And it cannot work, because the > > > > DSI host's binding specifies a single port: the input port from the > > > > display engine. > > > > > > Thanks for noticing this. I did understand your point and yes, I did > > > mention the updated pipeline in previous versions and forgot to add it > > > to this series. > > > > > > Here is the updated pipeline to make it work: > > > > > > https://patchwork.kernel.org/project/dri-devel/patch/20190524104252.20236-1-jagan@amarulasolutions.com/ > > > > > > Let me know your comments on this, so I will add a patch for the > > > above-affected DTS files. > > > > DT is an ABI, we need to ensure backward compatibility. Changes in > > kernel drivers can't break devices that have an old DT. > > Thanks for your point. > > So, we need to choose APIs that would compatible with the old DT and > new DT changes. Am I correct? Yes, that's correct. -- Regards, Laurent Pinchart _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel