From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=165.173.182.11 ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass; t=1796190389; b=aAwCWv3H5w2P6t0nTCHw7n65XL6YCZigbtoFWYZPoR8rnzUuikZgqkK6xVRqD1DZgG7K 5BJ+eZNBYilLrfmV2jwtv8nRAsbPbmMvNytKCuB4kGOt0bQHgKSPnos8K4yXahtmOL8RZ 8iQ8foDNBblHLtq3VFtnENt8RlaritgLIJBmdchGJkvCufXBhUG6QqY4Hc0aPUCXZWtF3 20QsTuaXwYSx4lG1LzD+hq5i+Pch6cCvYsjTjquOsFsjFN1GTiEHw7q154rLnG8+5Z4GB 94d20c0WvzyfJ3piNmMHqrdPbYpA96nqwMsi+2bOIiiI3lAZzP3xnXzi3AB/gMVK8mQ== ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796190389; h=DMARC-Filter:DKIM-Signature:Received:Received:Date:From:To:Cc: Subject:Message-ID:References:MIME-Version:Content-Type: Content-Disposition:In-Reply-To:X-Zoho-Virus-Status:X-Zoho-AV-Stamp: X-ZohoMailClient; bh=ol7plAJcLpx2WU+aiAzKlUaEwPewFagX4EfGvfhfYWs=; b=iqanf9yH5rEcTgch6VsJ4CzGvM9DFjt+tLX0KQORglXwGW0rv1C3NzKCGKye4jfu7/tV 2laYkvagB1TxxLpVfb17jCvMkm3Bzbs5gw2Jh1GeR1Z9h0JMFx7rRnYhGqaMCY9nCA2RM NahOxKm9pM9AZz87CCgOnhJ3Csf8Sio/6wzJwHqBquAtn9i3tDx64Xdv834NBI7CZcjsc Ku+jHFBrt1+PA0Ra9tm7dOmHAuusCOegge3/qjj8h68q2lFCvCwDyA/RTc0pPV4Hx6IPA hOZY3WNMrK24pXo7hoMF5xwgRbbT6ejrYT9VQ9YeqTArns4bvnGTtOqYcMhw32Bjf6w== ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass header.from=collabora.com; spf=pass smtp.mailfrom=collabora.com; dkim=pass header.d=collabora.com header.i=@collabora.com header.a=rsa-sha256 header.s=zohomail header.b=Vu+79KR2; arc=pass header.oldest-pass=0 smtp.remote-ip=165.173.182.11 Received: from sender5-op-o11.zoho.com (sender5-op-o11.zoho.com [165.173.182.11]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B9843606A337 for ; Wed, 2 Dec 2026 05:46:21 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org B9843606A337 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=collabora.com header.i=@collabora.com header.a=rsa-sha256 header.s=zohomail header.b=Vu+79KR2 ARC-Seal: i=1; a=rsa-sha256; t=1796190348; cv=none; d=zohomail.com; s=zohoarc; b=HGRc7d8VoiT7OrEHE2pPWgGbovDwfa/X+qAH8JJj4dkIpj0FKwM6P2kKd441U81ajBw2j73UeSSA+w7kfUzMFhdPF3pseW+mhWvkxpQ7M87Kbb4P/2pErC2hDQl5UqgPAmmTkihATwIVJFSph3x8ZUgPtY7SKV6ZLI4OQmE0XOU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1796190348; h=Content-Type:Cc:Cc:Date:Date:From:From:In-Reply-To:MIME-Version:Message-ID:Subject:Subject:To:To:Message-Id:Reply-To; bh=ol7plAJcLpx2WU+aiAzKlUaEwPewFagX4EfGvfhfYWs=; b=bnv8doDVh4ejR5mxXaE66tc2uXAavkT95JjfUBwL1ivThn10b7tzFpUm8XqVC/3OuwrQtr2twUwNHLGzcAO8tfAgX4tEKOIW/Y5UQTtSZ5xtuRwfx2qx0y5671swmSWY3r/xvnCbfZgOp/T75WFaWT0vokR6IG4zRGwbtLK0QGo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=collabora.com; spf=pass smtp.mailfrom=sebastian.reichel@collabora.com; dmarc=pass header.from= DKIM-Signature: a=rsa-sha256; b=Vu+79KR2Us9cNh8AglrMdU1m2RTOK87z3tNCoALHcJxkx0G32smyI7nEBYlUukKoL0MpIJHSVD9f4dvFHPOjyGg0LZivOE9of9LB4dI+P5H7wFxeWAhq35tHVE/5SGKZxhHdqXBHKeHbVRkyq5aKyuxcPNgUKe5+c1bXYJiGmrU=; c=relaxed/relaxed; s=zohomail; d=collabora.com; v=1; bh=ol7plAJcLpx2WU+aiAzKlUaEwPewFagX4EfGvfhfYWs=; h=Content-Description:Content-ID:Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Owner:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Resent-Sender:Resent-Cc:Resent-Date:Resent-To:Reply-To:Resent-Message-ID:Resent-From:Sender:Subject:To:Date:From:Message-Id:Reply-To:Subject:To:Cc; Received: by smtp.zohomail.com with SMTPS id 1796190345936512.5197017390485; Tue, 1 Dec 2026 21:45:45 -0800 (PST) Received: by venus (Postfix, from userid 1000) id 01517182056; Tue, 01 Dec 2026 23:16:09 +0100 (CET) Date: Tue, 1 Dec 2026 23:16:09 +0100 From: Sebastian Reichel To: aiyengar1990@gmail.com Cc: Vinod Koul , Neil Armstrong , Manivannan Sadhasivam , Heiko Stuebner , Philipp Zabel , Cristian Ciocaltea , Damon Ding , linux-phy@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org, Manivannan Sadhasivam Subject: Re: [PATCH v2] phy: rockchip: samsung-hdptx: Power down the lanes on phy_power_off() Message-ID: References: <20261130-hdptx-lanes-pwroff-v2-1-fee377304ef6@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-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="hxklnkn365du6mz5" Content-Disposition: inline In-Reply-To: <20261130-hdptx-lanes-pwroff-v2-1-fee377304ef6@gmail.com> X-Zoho-Virus-Status: 1 X-Zoho-AV-Stamp: zmail-av-0.2.28.1.5.5/296.168.99 X-ZohoMailClient: External --hxklnkn365du6mz5 Content-Type: text/plain; protected-headers=v1; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Subject: Re: [PATCH v2] phy: rockchip: samsung-hdptx: Power down the lanes on phy_power_off() MIME-Version: 1.0 Hi, On Mon, Nov 30, 2026 at 10:10:06PM +0000, Arun Iyengar via B4 Relay wrote: > From: Arun Iyengar >=20 > Since the PHY became a clock provider, rk_hdptx_phy_power_off() only > drops the usage count, which the consumers of the PHY PLL clock hold > too. On RK3588 the VOP holds it while runtime active, so with another > output in use the HDMI lanes keep driving the link after HDMI is > switched off. >=20 > Disable the lanes directly in rk_hdptx_phy_power_off() and keep the PLL > running for the clock consumers. DP mode is unchanged. Is there any gain from the DP check? It seems sensible to me to just always disable the lane in the power_off hook to have simpler code. Greetings, -- Sebastian > Fixes: c4b09c562086 ("phy: phy-rockchip-samsung-hdptx: Add clock provider= support") > Reviewed-by: Damon Ding > Reviewed-by: Heiko Stuebner > Reviewed-by: Manivannan Sadhasivam > Signed-off-by: Arun Iyengar > --- > Tested on an Orange Pi 5 (RK3588S): 102 HDMI off/on transitions over a > range of TMDS modes, picture back every time, lanes off (LNTOP_REG0207 > =3D 0) while off; three suspend-to-idle cycles resumed normally. >=20 > Developed with Claude (Anthropic) as a coding assistant; I reviewed and > tested it. > --- > Changes in v2: > - Shorter commit message (Damon); no code change > - Collected Reviewed-by tags > - Link to v1: https://patch.msgid.link/20261110-hdptx-lanes-pwroff-v1-1-c= 2f85b7e06a4@gmail.com > --- > drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c | 15 +++++++++++++++ > 1 file changed, 15 insertions(+) >=20 > diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/= phy/rockchip/phy-rockchip-samsung-hdptx.c > index 6879eecc5a9f..751bb503dcfe 100644 > --- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c > +++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c > @@ -1768,10 +1768,25 @@ static int rk_hdptx_phy_power_on(struct phy *phy) > return ret; > } > =20 > +static void rk_hdptx_lane_disable(struct rk_hdptx_phy *hdptx) > +{ > + regmap_update_bits(hdptx->regmap, LNTOP_REG(0207), LANE_EN_MASK, > + FIELD_PREP(LANE_EN_MASK, 0)); > + reset_control_assert(hdptx->rsts[RST_LANE].rstc); > +} > + > static int rk_hdptx_phy_power_off(struct phy *phy) > { > struct rk_hdptx_phy *hdptx =3D phy_get_drvdata(phy); > =20 > + /* > + * The lanes are owned by the PHY consumer alone, hence shut them > + * down right away. The PLL is shared with the clock consumers, so > + * leave its fate to the usage count. > + */ > + if (phy_get_mode(phy) !=3D PHY_MODE_DP) > + rk_hdptx_lane_disable(hdptx); > + > return rk_hdptx_phy_consumer_put(hdptx, false); > } > =20 >=20 > --- > base-commit: 6628e7d4c6b25c8d18f1345e3a20d21829aae7e4 > change-id: 20261110-hdptx-lanes-pwroff-5ddc6e3fabb2 >=20 > Best regards, > -- =20 > Arun Iyengar >=20 >=20 >=20 --hxklnkn365du6mz5 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEE72YNB0Y/i3JqeVQT2O7X88g7+poFAmsPRyYACgkQ2O7X88g7 +prIvA/+MvChOQLwtdD9ERZuCCAeSd/uI2B6FkiiqqKnMTaqGBDIW70yS8ZPeSQ7 bJQ57jr/xhdS4YJ2L4MozVqkqEaB1U2PepkbASfLlpFGlWtTFg2Xaoshz4Kp77Oh asxprOFpb3XwP+QZfAeyZ7Hv7LG4vRRXYQf2ZaE5X6KlkBsu83R/1i727pACfN9k 8GWstz3SOWMoizcmRaz8VD3Tyxd24KByZa/0bfuCTKOnBqKS61KvOZQDRhb1gb3T 8eqx1PoDwkTkRhsyD9027DbGA7gk3M1wTmvBMh4bss5meR9tVrF2nZvLbGQyQfHu zTtwt5uALYYkePOwWPf3WyzHRWNFoStYGhSOzW7M4pHOj/yaYheoJ9Un6swFZcGC oOP9bhU7B6apynHZSYb5X4bc8TKUDAuqCYyStgkMUEvWb6lKA2+4QHb7X9WAtwfd h/iyWiZW9VXIUFJmfP0bNERJX9viQBiijGaT68gZRFJffE+7EQBaKvUGV2Mpv1b+ yEcKQeAlFkXB8z4o17Mq+t6YbQETkWwwA3LoxtyQ9H90RL3rKBlqKWX1wxX2sdPr pfJYc5ICD0Tod57q7LW0CXStG8CzCuUPrUTawn0SluedV4k/aKPeDm1GYfGIkFEb 4OnqAGhlWa11F1ht6ETuUiDIB0m+ah4ZJT/FenUlB6XDoW/f1kM= =xT3l -----END PGP SIGNATURE----- --hxklnkn365du6mz5--