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 EE2A7C25B75 for ; Thu, 23 May 2024 18:58:17 +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:Message-ID:Date:References :In-Reply-To:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=vFaISRxBXnh0UK2vFMHNxjYkAoyZ0OoHeQl6KnaUo3k=; b=t4YVATDjzvfLOg +mVSx/R1W19KZSV8HGxAKrMUhybA2GIN+NpmC/EF/VfyPV3wJPp8Dd6NihRN/S2+PsR1EKIvrDJeW pzs9MSQC8DnRQqBGEpRq2IxKefTr5kwWZZ/B9HQ8kQa0uOdMcgfQFQeJJ0u8WF1vcvba2gErV5oQ9 IRyNaMhdgWYMaQfnat/82I+TWIOQz5GGiHhPNaJ2hzXWThkKFr0b6sNC5u9+7dKWQDkcvJ+dcZFih UnfLIl4wnJqQMKGZ1xRbGhy2hd6MzW9xKwwfDnNvCi7MoX0/UUGUdlX8D8EtyhiR9iXrUyDucT5GB B/o6aW7nBpTDGVFPYTmA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sADdg-000000074m5-4AGF; Thu, 23 May 2024 18:58:09 +0000 Received: from unicorn.mansr.com ([81.2.72.234]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sADde-000000074jC-2zUS for linux-arm-kernel@lists.infradead.org; Thu, 23 May 2024 18:58:08 +0000 Received: from raven.mansr.com (raven.mansr.com [IPv6:2001:8b0:ca0d:1::3]) by unicorn.mansr.com (Postfix) with ESMTPS id DA6A515364; Thu, 23 May 2024 19:58:00 +0100 (BST) Received: by raven.mansr.com (Postfix, from userid 51770) id CACE3219FCA; Thu, 23 May 2024 19:58:00 +0100 (BST) From: =?iso-8859-1?Q?M=E5ns_Rullg=E5rd?= To: Frank Oltmanns Cc: Michael Turquette , Stephen Boyd , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Guido =?iso-8859-1?Q?G=FCnther?= , Purism Kernel Team , Ondrej Jirman , Neil Armstrong , Jessica Zhang , Sam Ravnborg , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Daniel Vetter , Rob Herring , Krzysztof Kozlowski , Conor Dooley , linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, stable@vger.kernel.org Subject: Re: [PATCH v4 1/5] clk: sunxi-ng: common: Support minimum and maximum rate In-Reply-To: (=?iso-8859-1?Q?=22M=E5ns_Rullg?= =?iso-8859-1?Q?=E5rd=22's?= message of "Wed, 22 May 2024 19:07:21 +0100") References: <20240310-pinephone-pll-fixes-v4-0-46fc80c83637@oltmanns.dev> <20240310-pinephone-pll-fixes-v4-1-46fc80c83637@oltmanns.dev> Date: Thu, 23 May 2024 19:58:00 +0100 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.3 (gnu/linux) MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240523_115806_905776_E24B1418 X-CRM114-Status: GOOD ( 21.19 ) 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="iso-8859-1" Content-Transfer-Encoding: quoted-printable Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org M=E5ns Rullg=E5rd writes: > Frank Oltmanns writes: > >> Hi M=E5ns, >> >> 21.05.2024 15:43:10 M=E5ns Rullg=E5rd : >> >>> Frank Oltmanns writes: >>> >>>> The Allwinner SoC's typically have an upper and lower limit for their >>>> clocks' rates. Up until now, support for that has been implemented >>>> separately for each clock type. >>>> >>>> Implement that functionality in the sunxi-ng's common part making use = of >>>> the CCF rate liming capabilities, so that it is available for all clock >>>> types. >>>> >>>> Suggested-by: Maxime Ripard >>>> Signed-off-by: Frank Oltmanns >>>> Cc: stable@vger.kernel.org >>>> --- >>>> drivers/clk/sunxi-ng/ccu_common.c | 19 +++++++++++++++++++ >>>> drivers/clk/sunxi-ng/ccu_common.h |=A0 3 +++ >>>> 2 files changed, 22 insertions(+) >>> >>> This just landed in 6.6 stable, and it broke HDMI output on an A20 based >>> device, the clocks ending up all wrong as seen in this diff of >>> /sys/kernel/debug/clk/clk_summary: [...] >>> Reverting this commit makes it work again. >> >> Thank you for your detailed report! >> >> I've had a first look at hdmi-tmds and hdmi-ddc, and neither seems to >> be calling ccu_is_better_rate() in their determine_rate() >> functions. Their parents have the exact same rates in your diff, so, >> my current working assumption is that they can't be the cause either. >> >> I'll have a more detailed look over the weekend. Until then, if anyone >> has some ideas where I should have a look next, please share your >> thoughts. > > In case it's relevant, this system doesn't use the HDMI DDC, the > physical DDC pins being connected to a different I2C adapter for > various reasons. > > From the clk_summary diff, I see a few things: > > 1. hdmi-tmds has changed parent from pll-video1-2x to pll-video0-2x. > 2. The ratio of hdmi-tmds to its parent has changed from 1/8 to 1. > 3. The resulting rate bears no relation to the pixel clock from EDID. > > I tried kernel 6.9.1 as well, and that doesn't work either. I'll keep > digging and try to narrow it down. It turns out HDMI output is broken in v6.9 for a different reason. However, this commit (b914ec33b391 clk: sunxi-ng: common: Support minimum and maximum rate) requires two others as well in order not to break things on the A20: cedb7dd193f6 drm/sun4i: hdmi: Convert encoder to atomic 9ca6bc246035 drm/sun4i: hdmi: Move mode_set into enable With those two (the second depends on the first) cherry-picked on top of v6.6.31, the HDMI output is working again. Likewise on v6.8.10. -- = M=E5ns Rullg=E5rd _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel