Received: by 2002:a05:6358:5282:b0:b5:90e7:25cb with SMTP id g2csp3407603rwa; Tue, 23 Aug 2022 04:23:21 -0700 (PDT) X-Google-Smtp-Source: AA6agR4DdJArJJD07jsnuicyhkf5otkKq/S6zgr+ofoFu4/bb2F/UUpEWxXCo+hv1toOT5KZLJE8 X-Received: by 2002:a05:6a00:2354:b0:536:c154:2001 with SMTP id j20-20020a056a00235400b00536c1542001mr6996810pfj.34.1661253801680; Tue, 23 Aug 2022 04:23:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661253801; cv=none; d=google.com; s=arc-20160816; b=EhKz0F88UPqCClHN5I1CytRRPYMymikyvj0O4KGOz8qq2+73zIwilZyPTjhKRrA9pT CU8Lu1fYv9oxojLMCB9k0d9LD28aumuEGWckpiNTjfuMgiBy4j7N6vglueKFvgXzaD3M HMkAdXYNuz1vhemy0jbfrAnnBJu26G663US78Pa2qkHrsTqYM55oDEmy1/QSZERruX4m 07yC8Vba+9NrZQSa0QFcxFq+McB8teX/U0lCBIKN/KGtX8PPFYmp6vRm8zx4exWmGkeN 2u0nMoZzffjtu+ICR8kGsFUfkIk7VAaLIA1eph6nNmxNIKTfWJm1cdBsetHYCuGyRglF rhSQ== 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=h2yhZQlXe6BSU6P2VSml8XwdMUrfvUD9v77r3RSUBZ8=; b=PrsUrGFVRFvkW8RSpFhOHnU/Q5Cf7/6C7yuFvVxhZruNu8mUmFm4aJsx8vIhHxBM4Y H1OtlbFG8k+KyA3JimKaFtleptEod5lUCK95lHU5kjfbRtE2dnU2j3ptLHu+dMJUMgl0 DOQvfJFBssksWTJNY8RtEdAg3EBIUbEqsW7wtRewji3Tpk0EnOtHvijflLGpxgX2ifB6 gWtSimNWqwoCCnIhecA6ROZ2PUXmn7VNP0bu5GFRm7O27iUdb3H7u7ynDspAei7bcyyS nYeJ66k6h6lpSl5ew8cLPQmk2dduPjmHDcgDDL9vFAPvvL+aaQ/igg1s5elj5G5K1bbS gDsQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Du1hVkKa; 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 n13-20020a17090a670d00b001e895fed1e2si17233096pjj.130.2022.08.23.04.23.11; Tue, 23 Aug 2022 04:23:21 -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=Du1hVkKa; 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 S1351549AbiHWJhw (ORCPT + 99 others); Tue, 23 Aug 2022 05:37:52 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45938 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1351945AbiHWJgJ (ORCPT ); Tue, 23 Aug 2022 05:36:09 -0400 Received: from sin.source.kernel.org (sin.source.kernel.org [IPv6:2604:1380:40e1:4800::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2850C95E67; Tue, 23 Aug 2022 01:40:11 -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 sin.source.kernel.org (Postfix) with ESMTPS id 9E2D4CE1B4D; Tue, 23 Aug 2022 08:39:16 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B1DDBC433D6; Tue, 23 Aug 2022 08:39:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1661243955; bh=LZkjIvVaPJ5PQVliSAj7ZPU9g5VAT/t9LqW3Bx3TFh0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Du1hVkKaYey64ForIaKbyOOqp9Gml+/VNA5T/qyT9f1EHdesq2lti9BFkY/xLGo5v o0VveL6t43b01YZkm6oQIZa8tJMBFVXRRVUd3e3ZkaycOE3vUGsMsv5DwY6jm3xFHD 19cXO4BJHZFqthPRTnwrhTCfD2GAgevavF4JUPUU= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Jitao Shi , Xinlei Lee , Rex-BC Chen , Chun-Kuang Hu , Sasha Levin Subject: [PATCH 4.14 061/229] drm/mediatek: Add pull-down MIPI operation in mtk_dsi_poweroff function Date: Tue, 23 Aug 2022 10:23:42 +0200 Message-Id: <20220823080055.918335162@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220823080053.202747790@linuxfoundation.org> References: <20220823080053.202747790@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: Xinlei Lee [ Upstream commit fa5d0a0205c34734c5b8daa77e39ac2817f63a10 ] 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. If 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. Fixes: 2e54c14e310f ("drm/mediatek: Add DSI sub driver") Link: https://patchwork.kernel.org/project/linux-mediatek/patch/1653012007-11854-5-git-send-email-xinlei.lee@mediatek.com/ Signed-off-by: Jitao Shi Signed-off-by: Xinlei Lee Reviewed-by: Rex-BC Chen Signed-off-by: Chun-Kuang Hu Signed-off-by: Sasha Levin --- 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 c1b8caad65e6..7ae243122f68 100644 --- a/drivers/gpu/drm/mediatek/mtk_dsi.c +++ b/drivers/gpu/drm/mediatek/mtk_dsi.c @@ -652,6 +652,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 to pull down mipi */ + writel(0, dsi->regs + DSI_TXRX_CTRL); mtk_dsi_disable(dsi); -- 2.35.1