[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1919367.CQOukoFCf9@diego>
Date: Tue, 18 Feb 2025 11:00:57 +0100
From: Heiko Stübner <heiko@...ech.de>
To: cristian.ciocaltea@...labora.com, Jianfeng Liu <liujianfeng1994@...il.com>
Cc: airlied@...il.com, andy.yan@...k-chips.com, conor+dt@...nel.org,
devicetree@...r.kernel.org, dri-devel@...ts.freedesktop.org,
hjc@...k-chips.com, kernel@...labora.com, krzk+dt@...nel.org,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
linux-rockchip@...ts.infradead.org, liujianfeng1994@...il.com,
maarten.lankhorst@...ux.intel.com, mripard@...nel.org, robh@...nel.org,
simona@...ll.ch, tzimmermann@...e.de
Subject:
Re: [PATCH 3/4] arm64: dts: rockchip: Add HDMI1 PHY PLL clock source to VOP2
on RK3588
Am Dienstag, 18. Februar 2025, 10:52:16 MEZ schrieb Jianfeng Liu:
> Hi Cristian,
>
> No matter one or two hdmi ports the rk3588 boards have, most of
> devicetrees in mainline kernel only have hdmi0 supported. After applying
> this patch their hdmi0 support is broken.
>
> So I recommend moving the vop clk part to board level devicetree.
> Then support of hdmi0 won't be broken, and board maintainers can add
> HDMI1 PHY PLL clk when they are adding hdmi1 support. I can add support
> for orangepi 5 max and armsom w3 for reference by other developers.
better, fix the VOP2 driver - both for the existing hdmi0 + this hdmi1
please.
I.e. the clock is optional, and the error you are seeing comes from the
vop2->pll_hdmiphy1 = devm_clk_get_optional(vop2->dev, "pll_hdmiphy1");
if (IS_ERR(vop2->pll_hdmiphy1)) {
drm_err(vop2->drm, "failed to get pll_hdmiphy1\n");
return PTR_ERR(vop2->pll_hdmiphy1);
}
part. clk_get_optional is supposed to return NULL when clock-retrieval
causes a ENOENT error. Seemingly going to a clock controller in a disabled
node returns a different error?
So I guess step1, check what error is actually returned.
Step2 check if clk_get_optional need to be adapted or alternatively
catch the error in the vop2 and set the clock to NULL ourself in that case.
hdptxphy0 + hdpxphy1 _are_ valid supplies for the vop, so their reference
should be in the soc-dtsi and the kernel code should just figure things out
correctly. Wiggling with clocks in each board will cause headaches down
the road.
Heiko
Powered by blists - more mailing lists