From mboxrd@z Thu Jan 1 00:00:00 1970 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 AD2A222A4E1; Mon, 19 May 2025 21:22:25 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1747689745; cv=none; b=CEwMrtw6J1/idZQjcWzNOxHu8dZfwxCbPD9RrBNrrgowv9D/Hv7LWtvZO9RPkKMTGik38JY19QqKV1JkHJcZ1OWZPfdF63gqQL/oN3s7lhaKT1rEYvWGs37OIBfNniWqLkdpY4iScZGxLPagkxiBSeuEhT7Y7XwXK/TXGw0lX0k= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1747689745; c=relaxed/simple; bh=G736kJmx7ZAHce0+/nkrSSIWUxgBCRg1Sk81e42FNXE=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=brWz3q/gLKLbrCRbrecDSqCKxDZl+Im7MF5Ziih8BE5Ghes0MhrForniG/9zIjQp2eP31VQpZ+sZbsVrN9Il/jSgfLFCKJSIFsVv5lMQ48i5PiYwN4VaAKIUBQEP0cn7kBO12UgPd6yK/u8Fe5bPbE1KBBDINnYXU83J9HnqWBE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=oLYz38Oc; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="oLYz38Oc" Received: by smtp.kernel.org (Postfix) with ESMTPSA id E9C5BC4CEE9; Mon, 19 May 2025 21:22:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1747689745; bh=G736kJmx7ZAHce0+/nkrSSIWUxgBCRg1Sk81e42FNXE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=oLYz38OcO9vokB5OkrtdlwDJJXK7G7WfAD83pKcdBquS3B7ui5eIkZBQ97I+yLHru 4x9HkgEJXAXdUcHcGRtr/yBya0JTDHIIRQO6NXUGUx+rzTr3D4Jvw8fDAjWd5qtbVo BCNUhkSjBLw2s7XGCMczTTPrDe5MhC5OkQktk9In6cko2Wd3Ru9ZMMjSAOQuxpiX9i sslAFTGLpMCmIWkpO0V5QTJvhDMPJwlGJDoHwKmb/WV/NSm5GHqqTeUKk7ZcyyFgO1 REVVLfdLMMY87O6wQyGhOiuze3UfSCV54Tpep0rUymQh5hY8D9rgoLjITqaafzSZIU sdygTqjA9HRSw== From: Sasha Levin To: patches@lists.linux.dev, stable@vger.kernel.org Cc: Algea Cao , Cristian Ciocaltea , Heiko Stuebner , Vinod Koul , Sasha Levin , kishon@ti.com, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org Subject: [PATCH AUTOSEL 6.12 10/18] phy: phy-rockchip-samsung-hdptx: Fix PHY PLL output 50.25MHz error Date: Mon, 19 May 2025 17:21:59 -0400 Message-Id: <20250519212208.1986028-10-sashal@kernel.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20250519212208.1986028-1-sashal@kernel.org> References: <20250519212208.1986028-1-sashal@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore X-stable-base: Linux 6.12.29 Content-Transfer-Encoding: 8bit From: Algea Cao [ Upstream commit f9475055b11c0c70979bd1667a76b2ebae638eb7 ] When using HDMI PLL frequency division coefficient at 50.25MHz that is calculated by rk_hdptx_phy_clk_pll_calc(), it fails to get PHY LANE lock. Although the calculated values are within the allowable range of PHY PLL configuration. In order to fix the PHY LANE lock error and provide the expected 50.25MHz output, manually compute the required PHY PLL frequency division coefficient and add it to ropll_tmds_cfg configuration table. Signed-off-by: Algea Cao Reviewed-by: Cristian Ciocaltea Acked-by: Heiko Stuebner Link: https://lore.kernel.org/r/20250427095124.3354439-1-algea.cao@rock-chips.com Signed-off-by: Vinod Koul Signed-off-by: Sasha Levin --- drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c index be6f1ca9095aa..23a022da3f72d 100644 --- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c +++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c @@ -328,6 +328,8 @@ static const struct ropll_config ropll_tmds_cfg[] = { 1, 1, 0, 0x20, 0x0c, 1, 0x0e, 0, 0, }, { 650000, 162, 162, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 54, 0, 16, 4, 1, 1, 1, 0, 0x20, 0x0c, 1, 0x0e, 0, 0, }, + { 502500, 84, 84, 1, 1, 7, 1, 1, 1, 1, 1, 1, 1, 11, 1, 4, 5, + 4, 11, 1, 0, 0x20, 0x0c, 1, 0x0e, 0, 0, }, { 337500, 0x70, 0x70, 1, 1, 0xf, 1, 1, 1, 1, 1, 1, 1, 0x2, 0, 0x01, 5, 1, 1, 1, 0, 0x20, 0x0c, 1, 0x0e, 0, 0, }, { 400000, 100, 100, 1, 1, 11, 1, 1, 0, 1, 0, 1, 1, 0x9, 0, 0x05, 0, -- 2.39.5