From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=185.11.138.130 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1795972380; b=brDSax+JtCvXZwvQWs2AbBZK/4A7iV+fqcC+16l3zPic5+9vYajNTIUFjIrAlPLxi6VK FqPZjp1ndamRmWYDITLMpcOsRw/ifY+AoRemk0WaZxeFTPvs2fLpq5JSkckXgFn6iHrvH neGoKNYqmRhe15YAE2swjL+vWE3Vt/zqHBJ1tsKANT+NM71Z6mp7dsbU12qeQG1higk3z cMLfE+WKvfKApdBPbJILZqA6/zeFuVJWipHL6EE+bC8X4V/guzI02aiSw1v7/VhVpdRBS DejZzHMlSZPIZw6w7nK/EhW6r3d4Zlifpv9l/3prk1RVvyQgw3r8I5SsKhTpKTDmvOQ== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1795972380; h=DMARC-Filter:DKIM-Signature:From:To:Cc:Subject:Date:Message-ID: In-Reply-To:References:MIME-Version:Content-Transfer-Encoding: Content-Type; bh=GuPGXfTX3Ju+pBwD8YWKXfH5MHBYnePqcs0cVcgEW5M=; b=T+Kvj4nMyY2m/UJLnsphcUUBMgCv+SdQP5J7wItG40ATVXlgKNY8BfewOVrAC7YsuU++ RBk+sz5XB9cKV/swTiCU0zoaWXkmwqmwbalokqQY1mQhP8UEGiLxYoZvGnZrPOw+LwGtU vrmZe+Ln1Os0p5PnTt6hu4AyBoaft/O55s7Qctdc7Em8TWHXMokT6uqborYaGowNYZX+m 6xzRTwWeEAwos/ZrnbdBwLEIdtdTZ7EQKBhfUIYwcYcxeTVxX0sEvhwmlBSa004myIDtB wN8KDJ9hYmTpATPa00ScRrFmaRP/+T/f9Pdif9IQaNqzEFWSb7OpScCkOsh9VtKW/KA== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=sntech.de; spf=pass smtp.mailfrom=sntech.de; dkim=pass header.d=sntech.de header.i=@sntech.de header.a=rsa-sha256 header.s=gloria202408 header.b=d+okpkvl; arc=none smtp.remote-ip=185.11.138.130 Received: from gloria.sntech.de (gloria.sntech.de [185.11.138.130]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (prime256v1) server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A8E9F606A31C for ; Sun, 29 Nov 2026 17:12:59 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org A8E9F606A31C Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=sntech.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=sntech.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=sntech.de header.i=@sntech.de header.a=rsa-sha256 header.s=gloria202408 header.b=d+okpkvl DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sntech.de; s=gloria202408; h=Content-Type:Content-Transfer-Encoding:MIME-Version: References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From:Reply-To; bh=GuPGXfTX3Ju+pBwD8YWKXfH5MHBYnePqcs0cVcgEW5M=; b=d+okpkvlnQ/nbib0Z7vOSFvjPO fDiLIwt9XpM+/MowW8QXGKMk3my23Q+dHklKRi7Dun803u2xtxB+IbHWtmN0paOYN78HTioa+9Rfy YlCh8hJpM/PLQUWG4acw/vvTCJlJNL8CjUA8sfmA5tFf8HbYwCrh4LeaJW00o4hGxvYjCXtIaA3kM KOpz4V0thOA25yZoYfU7VcVLSLKCDv6BAFYThJiqy6B5vkmvk6IYKXJ5tfxFX55ca5oFfylacOi3/ 1U5zqg7LnFP1qE1HCwG7Hgu2sbTmmTBpJw2V+neMIxDLVu16Shr+FzXdR/0O/fB9MSdwWELuoJodC FRXOT5KQ==; From: Heiko Stuebner To: Vinod Koul , Neil Armstrong , Manivannan Sadhasivam , Philipp Zabel , Cristian Ciocaltea , aiyengar1990@gmail.com Cc: linux-phy@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] phy: rockchip: samsung-hdptx: Power down the lanes on phy_power_off() Date: Sun, 29 Nov 2026 18:12:52 +0100 Message-ID: <53_xeZk5SIWsPxtDV7trpA@sntech.de> In-Reply-To: <20261110-hdptx-lanes-pwroff-v1-1-c2f85b7e06a4@gmail.com> References: <20261110-hdptx-lanes-pwroff-v1-1-c2f85b7e06a4@gmail.com> X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Am Dienstag, 10. November 2026, 08:16:41 Mitteleurop=C3=A4ische Normalzeit = schrieb Arun Iyengar via B4 Relay: > From: Arun Iyengar >=20 > Since the PHY became a clock provider, rk_hdptx_phy_power_off() does > nothing but drop the shared usage count, and the PHY is only really > disabled when that count reaches zero. The count is also held by every > clock consumer of the PHY PLL, so with a clock reference outstanding > the lanes keep driving the link after the HDMI controller has asked for > the PHY to be powered off. >=20 > On RK3588 a clock reference is almost always outstanding: the VOP lists > the PHY clock among its clocks so it can source its DCLK from it, and > the Rockchip power domain driver puts every clock of a device under > pm_clk, which prepares the PHY clock (i.e. bumps the usage count) > whenever the VOP is runtime active. As soon as any other video port is > in use, e.g. a DP output, switching the HDMI CRTC off therefore leaves > the HDMI lanes enabled and the TMDS clock on the cable, so the sink > never sees the link go away. The lanes stay on until the whole VOP > goes to runtime suspend. >=20 > The lanes belong to the PHY consumer alone, whereas the PLL is shared > with the clock consumers. Hence disable the lane output and hold the > lanes in reset in rk_hdptx_phy_power_off() regardless of the usage > count, and keep leaving the PLL to the count. This is the state the > PHY is in between PLL and lane bring-up anyway, and the next > rk_hdptx_phy_power_on() restores the lanes through the regular > rk_hdptx_post_enable_lane() path, so no additional PLL re-init is > needed. The vendor driver does the same: its power_off callback only > clears the lane enable bits, leaving the PLL to the clock refcount. >=20 > The DP mode is left untouched: its PLL is not exposed as a clock and > the lanes are torn down by rk_hdptx_dp_reset() from the usage count. >=20 > Fixes: c4b09c562086 ("phy: phy-rockchip-samsung-hdptx: Add clock provider= support") > Signed-off-by: Arun Iyengar Reviewed-by: Heiko Stuebner