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 53841C433EF for ; Tue, 22 Mar 2022 05:59:46 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 6599910E60D; Tue, 22 Mar 2022 05:59:45 +0000 (UTC) Received: from mailgw02.mediatek.com (unknown [210.61.82.184]) by gabe.freedesktop.org (Postfix) with ESMTPS id EE08910E60D for ; Tue, 22 Mar 2022 05:59:43 +0000 (UTC) X-UUID: 79714d5203f94fcab3afdb250c341423-20220322 X-UUID: 79714d5203f94fcab3afdb250c341423-20220322 Received: from mtkmbs10n1.mediatek.inc [(172.21.101.34)] by mailgw02.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 759741181; Tue, 22 Mar 2022 13:59:37 +0800 Received: from mtkcas11.mediatek.inc (172.21.101.40) by mtkmbs07n1.mediatek.inc (172.21.101.16) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Tue, 22 Mar 2022 13:59:36 +0800 Received: from mszsdhlt06 (10.16.6.206) by mtkcas11.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Tue, 22 Mar 2022 13:59:35 +0800 Message-ID: Subject: Re: [PATCH v3,1/4] drm/mediatek: Adjust the timing of mipi signal from LP00 to LP11 From: xinlei.lee To: Rex-BC Chen , , , , , Date: Tue, 22 Mar 2022 13:59:56 +0800 In-Reply-To: <235c5bca8da7118bad6bb5cb3c8cba6e022e4411.camel@mediatek.com> References: <1647503611-13144-1-git-send-email-xinlei.lee@mediatek.com> <1647503611-13144-2-git-send-email-xinlei.lee@mediatek.com> <235c5bca8da7118bad6bb5cb3c8cba6e022e4411.camel@mediatek.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.2 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-MTK: N 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: jitao.shi@mediatek.com, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Project_Global_Chrome_Upstream_Group@mediatek.com, linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" On Thu, 2022-03-17 at 19:13 +0800, Rex-BC Chen wrote: > Hello Xinlei, > > Thanks for your patch, and there are something I want to know: > > On Thu, 2022-03-17 at 15:53 +0800, xinlei.lee@mediatek.com wrote: > > From: Jitao Shi > > > > Old sequence: > > 1. Pull the MIPI signal high > > 2. Delay & Dsi_reset > > 3. Set the dsi timing register > > 4. dsi clk & lanes leave ulp mode and enter hs mode > > > > New sequence: > > 1. Set the dsi timing register > > 2. Pull the MIPI signal high > > 3. Delay & Dsi_reset > > 4. dsi clk & lanes leave ulp mode and enter hs mode > > > > Could you explain why you want to change original power on sequence? > From this commit message, I don't know why you want to do this. > If the reason is in cover letter, I think you should move them here. > > > In the new sequence 2 & 3 & 4 will be moved to dsi_enbale in later > > patch. > > I think this is no need to describe here. > > BRs, > Rex > > > > Signed-off-by: Jitao Shi > > Signed-off-by: Xinlei Lee > > --- > > drivers/gpu/drm/mediatek/mtk_dsi.c | 6 +++--- > > 1 file changed, 3 insertions(+), 3 deletions(-) > > > > diff --git a/drivers/gpu/drm/mediatek/mtk_dsi.c > > b/drivers/gpu/drm/mediatek/mtk_dsi.c > > index ccb0511b9cd5..262c027d8c2f 100644 > > --- a/drivers/gpu/drm/mediatek/mtk_dsi.c > > +++ b/drivers/gpu/drm/mediatek/mtk_dsi.c > > @@ -649,14 +649,14 @@ static int mtk_dsi_poweron(struct mtk_dsi > > *dsi) > > mtk_dsi_reset_engine(dsi); > > mtk_dsi_phy_timconfig(dsi); > > > > - mtk_dsi_rxtx_control(dsi); > > - usleep_range(30, 100); > > - mtk_dsi_reset_dphy(dsi); > > mtk_dsi_ps_control_vact(dsi); > > mtk_dsi_set_vm_cmd(dsi); > > mtk_dsi_config_vdo_timing(dsi); > > mtk_dsi_set_interrupt_enable(dsi); > > > > + mtk_dsi_rxtx_control(dsi); > > + usleep_range(30, 100); > > + mtk_dsi_reset_dphy(dsi); > > mtk_dsi_clk_ulp_mode_leave(dsi); > > mtk_dsi_lane0_ulp_mode_leave(dsi); > > mtk_dsi_clk_hs_mode(dsi, 0); > > Hi Rex: Thanks for your review! Explain to you that this change does not actually affect the function of dsi. We have verified this. After this modification, it is convenient to move them into the if (!dsi->lanes_ready) condition, which is just an adjustment action. If you still have questions about my later explanation, please give another suggestion. Thanks! xinlei