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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7B8CCCCA47C for ; Tue, 14 Jun 2022 06:24:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1351119AbiFNGYj (ORCPT ); Tue, 14 Jun 2022 02:24:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57046 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237532AbiFNGYh (ORCPT ); Tue, 14 Jun 2022 02:24:37 -0400 Received: from mailgw02.mediatek.com (unknown [210.61.82.184]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8046725C6B; Mon, 13 Jun 2022 23:24:36 -0700 (PDT) X-UUID: c6ebceac8f7c40a1bf7afad08944afe9-20220614 X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.6,REQID:e089cde7-5d95-4aee-a8e9-a09a01500cce,OB:0,LO B:0,IP:0,URL:0,TC:0,Content:0,EDM:0,RT:0,SF:0,FILE:0,RULE:Release_Ham,ACTI ON:release,TS:0 X-CID-META: VersionHash:b14ad71,CLOUDID:29958407-b57a-4a25-a071-bc7b4972bc68,C OID:IGNORED,Recheck:0,SF:nil,TC:nil,Content:0,EDM:-3,IP:nil,URL:0,File:nil ,QS:nil,BEC:nil,COL:0 X-UUID: c6ebceac8f7c40a1bf7afad08944afe9-20220614 Received: from mtkmbs11n2.mediatek.inc [(172.21.101.187)] by mailgw02.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 1866991260; Tue, 14 Jun 2022 14:24:30 +0800 Received: from mtkcas11.mediatek.inc (172.21.101.40) by mtkmbs11n2.mediatek.inc (172.21.101.187) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.2.792.3; Tue, 14 Jun 2022 14:24:29 +0800 Received: from mtksdccf07 (172.21.84.99) by mtkcas11.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Tue, 14 Jun 2022 14:24:29 +0800 Message-ID: <9adfb4b98e505c10469395bf3038010024ab86fd.camel@mediatek.com> Subject: Re: [PATCH v11 11/12] drm/mediatek: dpi: Only enable dpi after the bridge is enabled From: CK Hu To: Bo-Chen Chen , , , , , , , CC: , , , , , , , , , , Date: Tue, 14 Jun 2022 14:24:29 +0800 In-Reply-To: <20220613064841.10481-12-rex-bc.chen@mediatek.com> References: <20220613064841.10481-1-rex-bc.chen@mediatek.com> <20220613064841.10481-12-rex-bc.chen@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 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, Bo-Chen: On Mon, 2022-06-13 at 14:48 +0800, Bo-Chen Chen wrote: > From: Guillaume Ranquet > > Enabling the dpi too early causes glitches on screen. > > Move the call to mtk_dpi_enable() at the end of the bridge_enable > callback to ensure everything is setup properly before enabling dpi. This seems a bug fix, so add Fixes tag on this patch. Regards, CK > > Signed-off-by: Guillaume Ranquet > Signed-off-by: Bo-Chen Chen > --- > drivers/gpu/drm/mediatek/mtk_dpi.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/gpu/drm/mediatek/mtk_dpi.c > b/drivers/gpu/drm/mediatek/mtk_dpi.c > index 08c8f21b4421..9668bd5dd14a 100644 > --- a/drivers/gpu/drm/mediatek/mtk_dpi.c > +++ b/drivers/gpu/drm/mediatek/mtk_dpi.c > @@ -480,7 +480,6 @@ static int mtk_dpi_power_on(struct mtk_dpi *dpi) > if (dpi->pinctrl && dpi->pins_dpi) > pinctrl_select_state(dpi->pinctrl, dpi->pins_dpi); > > - mtk_dpi_enable(dpi); > return 0; > > err_pixel: > @@ -726,6 +725,7 @@ static void mtk_dpi_bridge_enable(struct > drm_bridge *bridge) > > mtk_dpi_power_on(dpi); > mtk_dpi_set_display_mode(dpi, &dpi->mode); > + mtk_dpi_enable(dpi); > } > > static enum drm_mode_status