Received: by 2002:a05:7412:b995:b0:f9:9502:5bb8 with SMTP id it21csp6860300rdb; Tue, 2 Jan 2024 16:52:02 -0800 (PST) X-Google-Smtp-Source: AGHT+IFnXykPf5e2+sa1oE8453QX9T42wVvlqxWsT/V6HgNrfSs+4XtrsmVke/AOY3RKCYFwb67M X-Received: by 2002:a17:902:ced2:b0:1d0:6ffd:e2b8 with SMTP id d18-20020a170902ced200b001d06ffde2b8mr21302717plg.82.1704243122163; Tue, 02 Jan 2024 16:52:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704243122; cv=none; d=google.com; s=arc-20160816; b=sJ7D2WQiJerEh6Y+Lw3Al0oavnjE291vR/+7h523qDqq533OyLCZ47xn1qV2vTDbkI mJQE/PxIBCIFTpsweUSe5inetzmS2/si9Zq3abiGim7joFu7ZutHciss9YnUrClkU8L+ MjwB6/0GFb10oRKRpgtYOvZ6fsjpNLHVlOQ8fOb4DThvVKTSWx1doCcPdFakESA1EYND YCVLrN9aTys3i0LC5zs/jSGpmoSI/Z2gJj2I4SWahw3e+SNEJBtjvb24xDbXpnCiBfBT Ko00rQsOX9GCAJof6d3qudDF6WgxoF/dkclHth+F/OiCTxSxejNoIwWznarHZllHRNON SeEg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=user-agent:date:to:cc:from:subject:references:in-reply-to :content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:dkim-signature; bh=KLhlu+Ig+H0TvPySYQoZeTJbgKR0w5M/eY/SkqGs1Qw=; fh=T6AUCZeFgkJwP4WBqp2J7aiCKc8yqVMiUcfYOOpwLzU=; b=dv7rOI9ScNa+qHrcilXhwTCJ1KJ4OZIYFxhhMV2FDexruSjlax9g+R3bx0QNqP2JHl QnP8CRHomLDMptZy1LKsYrwK0giVG2FmFOIHk3j1/9aMO9i1Ov3M4PdbZOH+yDoI9A18 hsvU8hia3pDZlrFj4XRzAytMundfXSMArdwobyE+NJcHFSglLji/J+o7RdAvp5rhcgK1 PdvFQHljGiVz5HG1im4I0Pn0DL48LnBLz4u0JdLNvVS/KQsuLDL629+i/Nc93AB15rz0 6Y27Et2AMAuz4S7Ha9p3ftGPkqR8HEwrm1MjH7hsyf2MEPCWgQRrI7fhoccnlCBdQmkq hrCw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="Ixnmex/I"; spf=pass (google.com: domain of linux-kernel+bounces-15010-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-15010-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id u9-20020a17090341c900b001d457e73699si15115469ple.413.2024.01.02.16.52.01 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 02 Jan 2024 16:52:02 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-15010-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="Ixnmex/I"; spf=pass (google.com: domain of linux-kernel+bounces-15010-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-15010-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id CD232284970 for ; Wed, 3 Jan 2024 00:52:01 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E2B8EED5; Wed, 3 Jan 2024 00:51:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Ixnmex/I" X-Original-To: linux-kernel@vger.kernel.org Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 22384A56; Wed, 3 Jan 2024 00:51:43 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id D6563C433C7; Wed, 3 Jan 2024 00:51:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1704243103; bh=k9n78YdF+0o39NnDck1txg5213yk2YnfbSg31If7lfM=; h=In-Reply-To:References:Subject:From:Cc:To:Date:From; b=Ixnmex/I2/V9aSGETjWrbJ2IR2/EPlYoNULE96nHZCmWjLRG2RGSGS0eCBvnTsblu HzUF8Mv6uyqx6kIKd7+NzC6Sm96Myz/m8KEEWWOhOZcCTsoHJjFzVPatCYwrNks+K1 jJoPfBUanOuD2FeymRj8w/F9M3xwSlMVCOcf2WrNaITxyO7TPld5+at3CyNTCTMazE JUok9I5M5tjc5pQfpA1+1Er4p9dTW93QDvjzrk90ucJvIfrpA8hI24VP40vRMKVKSC t6LQDRZZsl82133Z/sJwRqwx6ZvB3wnP0d7MzD2Nx2ukeZ/vKQoAwg0bFMDsUwzgsx P9u+nbl35D8GQ== Message-ID: <65e4793fc4aaeadbda9b422e1ac8cc0c.sboyd@kernel.org> Content-Type: text/plain; charset="utf-8" Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable In-Reply-To: <20231103102533.69280-4-angelogioacchino.delregno@collabora.com> References: <20231103102533.69280-1-angelogioacchino.delregno@collabora.com> <20231103102533.69280-4-angelogioacchino.delregno@collabora.com> Subject: Re: [PATCH v3 3/3] clk: mediatek: mt8188-topckgen: Refactor parents for top_dp/edp muxes From: Stephen Boyd Cc: mturquette@baylibre.com, matthias.bgg@gmail.com, angelogioacchino.delregno@collabora.com, wenst@chromium.org, msp@baylibre.com, amergnat@baylibre.com, yangyingliang@huawei.com, u.kleine-koenig@pengutronix.de, linux-clk@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, kernel@collabora.com To: AngeloGioacchino Del Regno Date: Tue, 02 Jan 2024 16:51:40 -0800 User-Agent: alot/0.10 Quoting AngeloGioacchino Del Regno (2023-11-03 03:25:33) > The top_dp and top_edp muxes can be both parented to either TVDPLL1 > or TVDPLL2, two identically specced PLLs for the specific purpose of > giving out pixel clock: this becomes a problem when the MediaTek > DisplayPort Interface (DPI) driver tries to set the pixel clock rate. >=20 > In the usecase of two simultaneous outputs (using two controllers), > it was seen that one of the displays would sometimes display garbled > output (if any at all) and this was because: > - top_edp was set to TVDPLL1, outputting X GHz > - top_dp was set to TVDPLL2, outputting Y GHz > - mtk_dpi calls clk_set_rate(top_edp, Z GHz) > - top_dp is switched to TVDPLL1 > - TVDPLL1 changes its rate, top_edp outputs the wrong rate. > - eDP display is garbled >=20 > To solve this issue, remove all TVDPLL1 parents from `top_dp` and > all TVDPLL2 parents from `top_edp`, plus, necessarily switch both > clocks to use the new MUX_GATE_CLR_SET_UPD_INDEXED() macro to be > able to use the right bit index for the new parents list. >=20 > Signed-off-by: AngeloGioacchino Del Regno > --- Applied to clk-next