From: Cristian Ciocaltea <cristian.ciocaltea@collabora.com>
To: David Laight <david.laight.linux@gmail.com>
Cc: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>,
Vinod Koul <vkoul@kernel.org>,
Kishon Vijay Abraham I <kishon@kernel.org>,
Heiko Stuebner <heiko@sntech.de>,
Algea Cao <algea.cao@rock-chips.com>,
Sandor Yu <Sandor.yu@nxp.com>, Maxime Ripard <mripard@kernel.org>,
kernel@collabora.com, linux-kernel@vger.kernel.org,
linux-phy@lists.infradead.org,
linux-arm-kernel@lists.infradead.org,
linux-rockchip@lists.infradead.org
Subject: Re: [PATCH v5 07/12] phy: rockchip: samsung-hdptx: Avoid Hz<->hHz unit conversion overhead
Date: Mon, 10 Mar 2025 00:00:52 +0200 [thread overview]
Message-ID: <0fe4388f-3374-409b-8383-ee5200961583@collabora.com> (raw)
In-Reply-To: <20250309144747.744e5197@pumpkin>
On 3/9/25 4:47 PM, David Laight wrote:
> On Sun, 9 Mar 2025 12:13:32 +0200
> Cristian Ciocaltea <cristian.ciocaltea@collabora.com> wrote:
>
>> On 3/9/25 11:22 AM, Dmitry Baryshkov wrote:
>>> On Sat, 8 Mar 2025 at 14:21, Cristian Ciocaltea
>>> <cristian.ciocaltea@collabora.com> wrote:
>>>>
>>>> The ropll_tmds_cfg table used to identify the configuration params for
>>>> the supported rates expects the search key, i.e. bit_rate member of
>>>> struct ropll_config, to be provided in hHz rather than Hz (1 hHz = 100
>>>> Hz). This requires multiple conversions between these units being
>>>> performed at runtime.
>>>>
>>>> Improve implementation clarity and efficiency by consistently using the
>>>> Hz unit throughout driver's internal data structures and functions.
>>>> Also rename the rather misleading struct member.
>>>>
>>>> Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com>
>>>> ---
>>>> drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c | 79 +++++++++++------------
>>>> 1 file changed, 39 insertions(+), 40 deletions(-)
>>>>
>>>> diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
>>>> index 2bf525514c1991a1299265d12e1e85f66333c604..e58a01bdb3ce82d66acdcb02c06de2816288b574 100644
>>>> --- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
>>>> +++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
>>>> @@ -330,7 +330,7 @@ enum dp_link_rate {
>>>> };
>>>>
>>>> struct ropll_config {
>>>> - u32 bit_rate;
>>>> + u32 rate;
>>>
>>> unsigned long long, please, to match the tmds_char_rate type.
>
> Isn't 'bit_rate' more descriptive?
> But maybe rate_hz to make the units more obvious.
>
> If the max frequency might get near 4Gz then the you need something
The max freq. intended to be handled by the related config table is 600
MHz, that is for supporting HDMI 2.0 (TMDS). Anything above that
requires HDMI 2.1 (FRL), which is currently not provided and would
anyway not rely on this data structure.
Regards,
Cristian
_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip
next prev parent reply other threads:[~2025-03-09 22:02 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-08 12:21 [PATCH v5 00/12] phy: rockchip: samsung-hdptx: Support high color depth management Cristian Ciocaltea
2025-03-08 12:21 ` [PATCH v5 01/12] phy: Add HDMI configuration options Cristian Ciocaltea
2025-03-08 12:21 ` [PATCH v5 02/12] phy: hdmi: Add color depth configuration Cristian Ciocaltea
2025-03-09 9:16 ` Dmitry Baryshkov
2025-03-09 10:10 ` Cristian Ciocaltea
2025-03-09 10:10 ` Dmitry Baryshkov
2025-03-08 12:21 ` [PATCH v5 03/12] phy: rockchip: samsung-hdptx: Fix clock ratio setup Cristian Ciocaltea
2025-03-09 9:17 ` Dmitry Baryshkov
2025-03-09 10:11 ` Cristian Ciocaltea
2025-03-09 10:12 ` Dmitry Baryshkov
2025-03-09 10:17 ` Cristian Ciocaltea
2025-03-08 12:21 ` [PATCH v5 04/12] phy: rockchip: samsung-hdptx: Drop unused struct lcpll_config Cristian Ciocaltea
2025-03-09 9:18 ` Dmitry Baryshkov
2025-03-08 12:21 ` [PATCH v5 05/12] phy: rockchip: samsung-hdptx: Drop unused phy_cfg driver data Cristian Ciocaltea
2025-03-09 9:18 ` Dmitry Baryshkov
2025-03-08 12:21 ` [PATCH v5 06/12] phy: rockchip: samsung-hdptx: Drop superfluous cfgs " Cristian Ciocaltea
2025-03-09 9:19 ` Dmitry Baryshkov
2025-03-08 12:21 ` [PATCH v5 07/12] phy: rockchip: samsung-hdptx: Avoid Hz<->hHz unit conversion overhead Cristian Ciocaltea
2025-03-09 9:22 ` Dmitry Baryshkov
2025-03-09 10:13 ` Cristian Ciocaltea
2025-03-09 14:47 ` David Laight
2025-03-09 22:00 ` Cristian Ciocaltea [this message]
2025-03-08 12:21 ` [PATCH v5 08/12] phy: rockchip: samsung-hdptx: Setup TMDS char rate via phy_configure_opts_hdmi Cristian Ciocaltea
2025-03-09 9:26 ` Dmitry Baryshkov
2025-03-09 10:15 ` Cristian Ciocaltea
2025-03-18 12:48 ` Cristian Ciocaltea
2025-03-08 12:21 ` [PATCH v5 09/12] phy: rockchip: samsung-hdptx: Provide config params validation support Cristian Ciocaltea
2025-03-09 9:27 ` Dmitry Baryshkov
2025-03-08 12:21 ` [PATCH v5 10/12] phy: rockchip: samsung-hdptx: Restrict altering TMDS char rate via CCF Cristian Ciocaltea
2025-03-08 12:21 ` [PATCH v5 11/12] phy: rockchip: samsung-hdptx: Optimize internal rate handling Cristian Ciocaltea
2025-03-09 10:17 ` Dmitry Baryshkov
2025-03-09 10:32 ` Cristian Ciocaltea
2025-03-09 10:33 ` Dmitry Baryshkov
2025-03-08 12:21 ` [PATCH v5 12/12] phy: rockchip: samsung-hdptx: Add high color depth management Cristian Ciocaltea
2025-03-09 10:18 ` Dmitry Baryshkov
2025-03-18 12:56 ` Cristian Ciocaltea
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=0fe4388f-3374-409b-8383-ee5200961583@collabora.com \
--to=cristian.ciocaltea@collabora.com \
--cc=Sandor.yu@nxp.com \
--cc=algea.cao@rock-chips.com \
--cc=david.laight.linux@gmail.com \
--cc=dmitry.baryshkov@linaro.org \
--cc=heiko@sntech.de \
--cc=kernel@collabora.com \
--cc=kishon@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-phy@lists.infradead.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=mripard@kernel.org \
--cc=vkoul@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox