Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp3086658rwb; Mon, 15 Aug 2022 17:48:12 -0700 (PDT) X-Google-Smtp-Source: AA6agR5ra1GcV0L66fUKRBeC9LtLQEjUq8W1HxAIfMC3wYMkJmti/enVxpNYFxgeJKKU1x+q4kxI X-Received: by 2002:a17:907:7ea0:b0:730:a4e8:27bc with SMTP id qb32-20020a1709077ea000b00730a4e827bcmr11990516ejc.166.1660610891799; Mon, 15 Aug 2022 17:48:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660610891; cv=none; d=google.com; s=arc-20160816; b=J7BkdI3of4HV85H6hitjoKVs8DV1ddpa7yzDsk0gpxU4kfpGZbI819PBD7BlURn/V4 FLFegnHC9crB3UYKVoXk21NuCyXKmGEo/zpt0zB1nMowb+5fhOt+5iz1WFL12W/D/DLf 8zqzvM4uq7pGoBX6f/3h8zI0eZbHULRPjZ4LKdYOQlKeqvXXw6N1b1E3j2AgvR6ghqcc rkKGBY78Bb2hTFVWOvkMAfHtHy8e6fDgXSRJj27Z4pBl3QxmMgDv1nponBhLzpTyc2qX faeq7qc3FeL/d/rPMGn0OWOT3/U6/JbOtVHGXNwCcVmlRWYMwOQ2OQOwuSb+f84MQp88 7Org== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=mYukoJh6Qx6w9teUa80UvmfIa0pftqMBr2nQHhwZsmk=; b=IbPYuOlBrzsYnmWI4eOWLovbExWRaPyewDZEK+NC4Zs2/tx7JQUy+V7okxOn02wL1+ VYKdXYsCEJqFVeBsnhLupDFCleDn1JJ76X+exSCB0oYcu+UWxlN1vZKizmZyxxtr9ZvR OondP72O0+o3ZjCChWJORO9HnFoinK8kLtUgPvxr+Rinqqhis1kvT5UMs6Ze2G95uTiD uPlzQhi37LM4s16u0in1UVXWj3ygoKLZgL9v2PCL1SEcpCcosnhI0yO++BMjVEcruvtW vhIjvUo5EOOwGEn6YfFS9lrN03QtV7XVd3/dxf0Lgp247jBC0slFPcoB8uEvEP7H4Uzf UFXw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=cvOFvV7O; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f13-20020a0564021e8d00b0043d85ca3c96si9162630edf.440.2022.08.15.17.47.46; Mon, 15 Aug 2022 17:48:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=cvOFvV7O; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1354443AbiHOXsQ (ORCPT + 99 others); Mon, 15 Aug 2022 19:48:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60804 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1354428AbiHOXmJ (ORCPT ); Mon, 15 Aug 2022 19:42:09 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9C8BC32EC0; Mon, 15 Aug 2022 13:13:29 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 9A5E4B80EA8; Mon, 15 Aug 2022 20:13:27 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id DF14FC433D6; Mon, 15 Aug 2022 20:13:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1660594406; bh=ZCTlZ6oiSDxVQ1XvejSCzZ84C+U5CBdJqQG1WcctKyc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=cvOFvV7ORMeu7XMQpriZhya4GjiKuHWRiQC/ij3Yu2H7vvpnW3gbOCwLthkgohmXQ DRL1sP03V+qs1E4hXXLdGHtynf/P6svT9v72FTy6Vvi5H+SU1CriBUUl7tJXl+BZjK Xv/SwKjbUfgg7POrO7t0ec8ORefXyVPoZd1NI6Ek= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Guillaume Ranquet , Bo-Chen Chen , AngeloGioacchino Del Regno , Chun-Kuang Hu , Sasha Levin Subject: [PATCH 5.19 0435/1157] drm/mediatek: dpi: Only enable dpi after the bridge is enabled Date: Mon, 15 Aug 2022 19:56:31 +0200 Message-Id: <20220815180457.049435147@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220815180439.416659447@linuxfoundation.org> References: <20220815180439.416659447@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Guillaume Ranquet [ Upstream commit aed61ef6beb911cc043af0f2f291167663995065 ] 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. Fixes: 9e629c17aa8d ("drm/mediatek: Add DPI sub driver") Signed-off-by: Guillaume Ranquet Signed-off-by: Bo-Chen Chen Tested-by: AngeloGioacchino Del Regno Link: https://patchwork.kernel.org/project/linux-mediatek/patch/20220701035845.16458-16-rex-bc.chen@mediatek.com/ Signed-off-by: Chun-Kuang Hu Signed-off-by: Sasha Levin --- 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 675e2e4072df..41c783349321 100644 --- a/drivers/gpu/drm/mediatek/mtk_dpi.c +++ b/drivers/gpu/drm/mediatek/mtk_dpi.c @@ -417,7 +417,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: @@ -639,6 +638,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 -- 2.35.1