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 65C39C433F5 for ; Tue, 22 Mar 2022 10:00:18 +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-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Date:CC:To:From:Subject:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=d4SZUdDKlKQu9FX81epa0O8EpVyDs5AbRhsWXMqwjQU=; b=0IqP2OVATcVpVS efeoTFxm0q/T++2y2N3J2KuQAqcInBi1/8m2dW16hcvMmXQp1H4TJfYvBb5MrqfLTC1SHanUjLITF 9cWMHw8AjmPT2lIQzD+Lj5qMLUdMbrxJc94M2QiS04emIZ/dWH/rZAfjFC0N+xTH+Av14gIxiDYMa Y8pH9MOnrYyh9yFUPFhQDQCp7kDuWVjfHE5Kduoyc/0LUanfITzM+qVhUcxvV4oBpQM98CpIxZGk1 kgv6l8LV729nDmosH65QI5cXE3VHXCGi92rF8UOPnB68CfpN/W8giYrniEM12CFyKsibIA2S1BoWL ReZkj/pKytdrcDpBMdKA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nWbJF-00Af7v-0J; Tue, 22 Mar 2022 10:00:13 +0000 Received: from mailgw01.mediatek.com ([216.200.240.184]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nWbJC-00Af7N-LQ; Tue, 22 Mar 2022 10:00:12 +0000 X-UUID: 8928262ff5f049a490f8d8aa82b98291-20220322 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Transfer-Encoding:MIME-Version:Content-Type:References:In-Reply-To:Date:CC:To:From:Subject:Message-ID; bh=803QjYBM9TC9/gGxHXbmDE6nVV/Vo+kxPLk/Xcp+MZE=; b=s3v2A8LAmMiaw0FCi4cF5rcjdT8O089KtHBtl8H/zmgv3xIhst1YnBzBffylve7yd0Qs+NOtzeQ9K5cRAv29R7aRkiZ1ppyCKHRn0okQ8NzGmyTYrLRcO6kZAAwHUXV8SkZ3E/7XdKv5IULx4QYY2nDRYrYG8nTWlQIAia0GePU=; X-UUID: 8928262ff5f049a490f8d8aa82b98291-20220322 Received: from mtkcas66.mediatek.inc [(172.29.193.44)] by mailgw01.mediatek.com (envelope-from ) (musrelay.mediatek.com ESMTP with TLSv1.2 ECDHE-RSA-AES256-SHA384 256/256) with ESMTP id 99002686; Tue, 22 Mar 2022 03:00:07 -0700 Received: from mtkmbs10n2.mediatek.inc (172.21.101.183) by MTKMBS62N2.mediatek.inc (172.29.193.42) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Tue, 22 Mar 2022 03:00:05 -0700 Received: from mtkcas10.mediatek.inc (172.21.101.39) by mtkmbs10n2.mediatek.inc (172.21.101.183) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.2.792.3; Tue, 22 Mar 2022 18:00:04 +0800 Received: from mszsdhlt06 (10.16.6.206) by mtkcas10.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Tue, 22 Mar 2022 18:00:03 +0800 Message-ID: <55eba6e4285ee6e4edb436f339b88730cc2c651c.camel@mediatek.com> Subject: Re: [PATCH v3,4/4] drm/mediatek: Add pull-down MIPI operation in mtk_dsi_poweroff function From: xinlei.lee To: Rex-BC Chen , , , , , CC: , , , , , Date: Tue, 22 Mar 2022 18:00:24 +0800 In-Reply-To: References: <1647503611-13144-1-git-send-email-xinlei.lee@mediatek.com> <1647503611-13144-5-git-send-email-xinlei.lee@mediatek.com> X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.2 MIME-Version: 1.0 X-MTK: N X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220322_030010_736196_A060D4F8 X-CRM114-Status: GOOD ( 20.74 ) X-BeenThere: linux-mediatek@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-mediatek" Errors-To: linux-mediatek-bounces+linux-mediatek=archiver.kernel.org@lists.infradead.org On Thu, 2022-03-17 at 20:20 +0800, Rex-BC Chen wrote: > Hello Xinlei, > > On Thu, 2022-03-17 at 15:53 +0800, xinlei.lee@mediatek.com wrote: > > From: Xinlei Lee > > > > In the dsi_enable function, mtk_dsi_rxtx_control is to > > pull up the MIPI signal operation. Before dsi_disable, > > MIPI should also be pulled down by writing a register instead of > > disabling dsi. > > > > What will happen if you do not pulled down the mipi before disable > dsi? > What's differnet for this two setting? > > > Signed-off-by: Jitao Shi > > Signed-off-by: Xinlei Lee > > --- > > drivers/gpu/drm/mediatek/mtk_dsi.c | 2 ++ > > 1 file changed, 2 insertions(+) > > > > diff --git a/drivers/gpu/drm/mediatek/mtk_dsi.c > > b/drivers/gpu/drm/mediatek/mtk_dsi.c > > index b509d59235e2..1c6a75a46b67 100644 > > --- a/drivers/gpu/drm/mediatek/mtk_dsi.c > > +++ b/drivers/gpu/drm/mediatek/mtk_dsi.c > > @@ -676,6 +676,8 @@ static void mtk_dsi_poweroff(struct mtk_dsi > > *dsi) > > mtk_dsi_reset_engine(dsi); > > mtk_dsi_lane0_ulp_mode_enter(dsi); > > mtk_dsi_clk_ulp_mode_enter(dsi); > > + /* set the lane number as 0 */ > > + writel(0, dsi->regs + DSI_TXRX_CTRL); > > So set lane num to 0 means pull down mipi? > > BRs, > Rex > > > > > mtk_dsi_disable(dsi); > > > > Hi rex: 1. If you disable dsi without pulling the mipi signal low, the value of the register will still maintain the setting of the mipi signal being pulled high. After resume, even if the mipi signal is not pulled high, it will still be in the high state. 2.So set lane num to 0 means pull down mipi => yes Do you have any suggestions on the next version? Best Regards! xinlei _______________________________________________ Linux-mediatek mailing list Linux-mediatek@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-mediatek 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 45F8AC433EF for ; Tue, 22 Mar 2022 10:00:13 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 7664810E0CD; Tue, 22 Mar 2022 10:00:12 +0000 (UTC) Received: from mailgw02.mediatek.com (unknown [210.61.82.184]) by gabe.freedesktop.org (Postfix) with ESMTPS id E135310E0CD for ; Tue, 22 Mar 2022 10:00:10 +0000 (UTC) X-UUID: b5fe3251858a466aa4a657ced4731cfb-20220322 X-UUID: b5fe3251858a466aa4a657ced4731cfb-20220322 Received: from mtkcas11.mediatek.inc [(172.21.101.40)] by mailgw02.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-SHA384 256/256) with ESMTP id 1537663108; Tue, 22 Mar 2022 18:00:04 +0800 Received: from mtkcas10.mediatek.inc (172.21.101.39) by mtkmbs10n2.mediatek.inc (172.21.101.183) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.2.792.3; Tue, 22 Mar 2022 18:00:04 +0800 Received: from mszsdhlt06 (10.16.6.206) by mtkcas10.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Tue, 22 Mar 2022 18:00:03 +0800 Message-ID: <55eba6e4285ee6e4edb436f339b88730cc2c651c.camel@mediatek.com> Subject: Re: [PATCH v3,4/4] drm/mediatek: Add pull-down MIPI operation in mtk_dsi_poweroff function From: xinlei.lee To: Rex-BC Chen , , , , , Date: Tue, 22 Mar 2022 18:00:24 +0800 In-Reply-To: References: <1647503611-13144-1-git-send-email-xinlei.lee@mediatek.com> <1647503611-13144-5-git-send-email-xinlei.lee@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 20:20 +0800, Rex-BC Chen wrote: > Hello Xinlei, > > On Thu, 2022-03-17 at 15:53 +0800, xinlei.lee@mediatek.com wrote: > > From: Xinlei Lee > > > > In the dsi_enable function, mtk_dsi_rxtx_control is to > > pull up the MIPI signal operation. Before dsi_disable, > > MIPI should also be pulled down by writing a register instead of > > disabling dsi. > > > > What will happen if you do not pulled down the mipi before disable > dsi? > What's differnet for this two setting? > > > Signed-off-by: Jitao Shi > > Signed-off-by: Xinlei Lee > > --- > > drivers/gpu/drm/mediatek/mtk_dsi.c | 2 ++ > > 1 file changed, 2 insertions(+) > > > > diff --git a/drivers/gpu/drm/mediatek/mtk_dsi.c > > b/drivers/gpu/drm/mediatek/mtk_dsi.c > > index b509d59235e2..1c6a75a46b67 100644 > > --- a/drivers/gpu/drm/mediatek/mtk_dsi.c > > +++ b/drivers/gpu/drm/mediatek/mtk_dsi.c > > @@ -676,6 +676,8 @@ static void mtk_dsi_poweroff(struct mtk_dsi > > *dsi) > > mtk_dsi_reset_engine(dsi); > > mtk_dsi_lane0_ulp_mode_enter(dsi); > > mtk_dsi_clk_ulp_mode_enter(dsi); > > + /* set the lane number as 0 */ > > + writel(0, dsi->regs + DSI_TXRX_CTRL); > > So set lane num to 0 means pull down mipi? > > BRs, > Rex > > > > > mtk_dsi_disable(dsi); > > > > Hi rex: 1. If you disable dsi without pulling the mipi signal low, the value of the register will still maintain the setting of the mipi signal being pulled high. After resume, even if the mipi signal is not pulled high, it will still be in the high state. 2.So set lane num to 0 means pull down mipi => yes Do you have any suggestions on the next version? Best Regards! xinlei 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 C6DD8C433F5 for ; Tue, 22 Mar 2022 10:01:27 +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-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Date:CC:To:From:Subject:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=HMGb7I8PjxxwNpjveuvMwANJyB9SQS/1W21IFHpQkk4=; b=OtNI6SCWyB/t6s 8X86aj6yO7RpVXNaiXSmcKFYc4A85LxHcPN/I0ZyMuCmBBovQqvVzTNDBP8aauTnL4Oth1Z487jNa vM9ZdU54F9dFh6tjJvz0EX3CjS80wyJL4HKtN+UziIxCjxyzGhAL4pOBE0Lsuf+zTdpNVRMZ6xpko 5sbAn8c2Hog6T9+s+hocq7DzWx1rkSKg8OgG0YcZo8Dp3fJEB3qlT7ZDyt7JsTGszBxlwhu01k1Eq MgU3/lprI+42qGL/lGR5bck7bkTP2WQfSaqSMxdQKvWARtBY4hmhECKYOMpO17TQWUe8jeEnoA+9i qVIH9+iOWYJ5oy/VcN0Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nWbJG-00Af83-Df; Tue, 22 Mar 2022 10:00:14 +0000 Received: from mailgw01.mediatek.com ([216.200.240.184]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nWbJC-00Af7N-LQ; Tue, 22 Mar 2022 10:00:12 +0000 X-UUID: 8928262ff5f049a490f8d8aa82b98291-20220322 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Transfer-Encoding:MIME-Version:Content-Type:References:In-Reply-To:Date:CC:To:From:Subject:Message-ID; bh=803QjYBM9TC9/gGxHXbmDE6nVV/Vo+kxPLk/Xcp+MZE=; b=s3v2A8LAmMiaw0FCi4cF5rcjdT8O089KtHBtl8H/zmgv3xIhst1YnBzBffylve7yd0Qs+NOtzeQ9K5cRAv29R7aRkiZ1ppyCKHRn0okQ8NzGmyTYrLRcO6kZAAwHUXV8SkZ3E/7XdKv5IULx4QYY2nDRYrYG8nTWlQIAia0GePU=; X-UUID: 8928262ff5f049a490f8d8aa82b98291-20220322 Received: from mtkcas66.mediatek.inc [(172.29.193.44)] by mailgw01.mediatek.com (envelope-from ) (musrelay.mediatek.com ESMTP with TLSv1.2 ECDHE-RSA-AES256-SHA384 256/256) with ESMTP id 99002686; Tue, 22 Mar 2022 03:00:07 -0700 Received: from mtkmbs10n2.mediatek.inc (172.21.101.183) by MTKMBS62N2.mediatek.inc (172.29.193.42) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Tue, 22 Mar 2022 03:00:05 -0700 Received: from mtkcas10.mediatek.inc (172.21.101.39) by mtkmbs10n2.mediatek.inc (172.21.101.183) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.2.792.3; Tue, 22 Mar 2022 18:00:04 +0800 Received: from mszsdhlt06 (10.16.6.206) by mtkcas10.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Tue, 22 Mar 2022 18:00:03 +0800 Message-ID: <55eba6e4285ee6e4edb436f339b88730cc2c651c.camel@mediatek.com> Subject: Re: [PATCH v3,4/4] drm/mediatek: Add pull-down MIPI operation in mtk_dsi_poweroff function From: xinlei.lee To: Rex-BC Chen , , , , , CC: , , , , , Date: Tue, 22 Mar 2022 18:00:24 +0800 In-Reply-To: References: <1647503611-13144-1-git-send-email-xinlei.lee@mediatek.com> <1647503611-13144-5-git-send-email-xinlei.lee@mediatek.com> X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.2 MIME-Version: 1.0 X-MTK: N X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220322_030010_736196_A060D4F8 X-CRM114-Status: GOOD ( 20.74 ) 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 On Thu, 2022-03-17 at 20:20 +0800, Rex-BC Chen wrote: > Hello Xinlei, > > On Thu, 2022-03-17 at 15:53 +0800, xinlei.lee@mediatek.com wrote: > > From: Xinlei Lee > > > > In the dsi_enable function, mtk_dsi_rxtx_control is to > > pull up the MIPI signal operation. Before dsi_disable, > > MIPI should also be pulled down by writing a register instead of > > disabling dsi. > > > > What will happen if you do not pulled down the mipi before disable > dsi? > What's differnet for this two setting? > > > Signed-off-by: Jitao Shi > > Signed-off-by: Xinlei Lee > > --- > > drivers/gpu/drm/mediatek/mtk_dsi.c | 2 ++ > > 1 file changed, 2 insertions(+) > > > > diff --git a/drivers/gpu/drm/mediatek/mtk_dsi.c > > b/drivers/gpu/drm/mediatek/mtk_dsi.c > > index b509d59235e2..1c6a75a46b67 100644 > > --- a/drivers/gpu/drm/mediatek/mtk_dsi.c > > +++ b/drivers/gpu/drm/mediatek/mtk_dsi.c > > @@ -676,6 +676,8 @@ static void mtk_dsi_poweroff(struct mtk_dsi > > *dsi) > > mtk_dsi_reset_engine(dsi); > > mtk_dsi_lane0_ulp_mode_enter(dsi); > > mtk_dsi_clk_ulp_mode_enter(dsi); > > + /* set the lane number as 0 */ > > + writel(0, dsi->regs + DSI_TXRX_CTRL); > > So set lane num to 0 means pull down mipi? > > BRs, > Rex > > > > > mtk_dsi_disable(dsi); > > > > Hi rex: 1. If you disable dsi without pulling the mipi signal low, the value of the register will still maintain the setting of the mipi signal being pulled high. After resume, even if the mipi signal is not pulled high, it will still be in the high state. 2.So set lane num to 0 means pull down mipi => yes Do you have any suggestions on the next version? Best Regards! xinlei _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel