2024-02-01 14:24:29

by Jayesh Choudhary

[permalink] [raw]
Subject: [RESEND PATCH v2] arm64: dts: ti: k3-am69-sk: remove assigned-clock-parents for unused VP

VP2 and VP3 are unused video ports and VP3 share the same parent
clock as VP1 causing issue with pixel clock setting for HDMI (VP1).
The current DM firmware does not support changing parent clock if it
is shared by another component. It returns 0 for the determine_rate
query before causing set_rate to set the clock at default maximum of
1.8GHz which is a lot more than the maximum frequency videoports can
support (600MHz) causing SYNC LOST issues.
So remove the parent clocks for unused VPs to avoid conflict.

Fixes: 6f8605fd7d11 ("arm64: dts: ti: k3-am69-sk: Add DP and HDMI support")
Reported-by: Nishanth Menon <[email protected]>
Signed-off-by: Jayesh Choudhary <[email protected]>
Reviewed-by: Tomi Valkeinen <[email protected]>
---

v1: <https://lore.kernel.org/all/[email protected]/>

Changelog v1->v2:
- Updated commit message
- Picked up Tomi's R-by from v1
- Removed "Closes:" link since its invalid now

(NOTE: Sending again as forgot to put mailing list in cc earlier)

arch/arm64/boot/dts/ti/k3-am69-sk.dts | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/arch/arm64/boot/dts/ti/k3-am69-sk.dts b/arch/arm64/boot/dts/ti/k3-am69-sk.dts
index 8da591579868..370980eb59b0 100644
--- a/arch/arm64/boot/dts/ti/k3-am69-sk.dts
+++ b/arch/arm64/boot/dts/ti/k3-am69-sk.dts
@@ -918,13 +918,9 @@ &dss {
pinctrl-names = "default";
pinctrl-0 = <&dss_vout0_pins_default>;
assigned-clocks = <&k3_clks 218 2>,
- <&k3_clks 218 5>,
- <&k3_clks 218 14>,
- <&k3_clks 218 18>;
+ <&k3_clks 218 5>;
assigned-clock-parents = <&k3_clks 218 3>,
- <&k3_clks 218 7>,
- <&k3_clks 218 16>,
- <&k3_clks 218 22>;
+ <&k3_clks 218 7>;
};

&serdes_wiz4 {
--
2.25.1



2024-02-02 05:17:12

by Aradhya Bhatia

[permalink] [raw]
Subject: Re: [RESEND PATCH v2] arm64: dts: ti: k3-am69-sk: remove assigned-clock-parents for unused VP



On 01-Feb-24 19:53, Jayesh Choudhary wrote:
> VP2 and VP3 are unused video ports and VP3 share the same parent
> clock as VP1 causing issue with pixel clock setting for HDMI (VP1).
> The current DM firmware does not support changing parent clock if it
> is shared by another component. It returns 0 for the determine_rate
> query before causing set_rate to set the clock at default maximum of
> 1.8GHz which is a lot more than the maximum frequency videoports can
> support (600MHz) causing SYNC LOST issues.
> So remove the parent clocks for unused VPs to avoid conflict.
>
> Fixes: 6f8605fd7d11 ("arm64: dts: ti: k3-am69-sk: Add DP and HDMI support")
> Reported-by: Nishanth Menon <[email protected]>
> Signed-off-by: Jayesh Choudhary <[email protected]>
> Reviewed-by: Tomi Valkeinen <[email protected]>

Reviewed-by: Aradhya Bhatia <[email protected]>

Regards
Aradhya

> ---
>
> v1: <https://lore.kernel.org/all/[email protected]/>
>
> Changelog v1->v2:
> - Updated commit message
> - Picked up Tomi's R-by from v1
> - Removed "Closes:" link since its invalid now
>
> (NOTE: Sending again as forgot to put mailing list in cc earlier)
>
> arch/arm64/boot/dts/ti/k3-am69-sk.dts | 8 ++------
> 1 file changed, 2 insertions(+), 6 deletions(-)
>
> diff --git a/arch/arm64/boot/dts/ti/k3-am69-sk.dts b/arch/arm64/boot/dts/ti/k3-am69-sk.dts
> index 8da591579868..370980eb59b0 100644
> --- a/arch/arm64/boot/dts/ti/k3-am69-sk.dts
> +++ b/arch/arm64/boot/dts/ti/k3-am69-sk.dts
> @@ -918,13 +918,9 @@ &dss {
> pinctrl-names = "default";
> pinctrl-0 = <&dss_vout0_pins_default>;
> assigned-clocks = <&k3_clks 218 2>,
> - <&k3_clks 218 5>,
> - <&k3_clks 218 14>,
> - <&k3_clks 218 18>;
> + <&k3_clks 218 5>;
> assigned-clock-parents = <&k3_clks 218 3>,
> - <&k3_clks 218 7>,
> - <&k3_clks 218 16>,
> - <&k3_clks 218 22>;
> + <&k3_clks 218 7>;
> };
>
> &serdes_wiz4 {

2024-02-05 17:58:51

by Enric Balletbo i Serra

[permalink] [raw]
Subject: Re: [RESEND PATCH v2] arm64: dts: ti: k3-am69-sk: remove assigned-clock-parents for unused VP

Hi Jayesh,

Many thanks for the patch.

On Fri, Feb 2, 2024 at 6:17 AM Aradhya Bhatia <[email protected]> wrote:
>
>
>
> On 01-Feb-24 19:53, Jayesh Choudhary wrote:
> > VP2 and VP3 are unused video ports and VP3 share the same parent
> > clock as VP1 causing issue with pixel clock setting for HDMI (VP1).
> > The current DM firmware does not support changing parent clock if it
> > is shared by another component. It returns 0 for the determine_rate
> > query before causing set_rate to set the clock at default maximum of
> > 1.8GHz which is a lot more than the maximum frequency videoports can
> > support (600MHz) causing SYNC LOST issues.
> > So remove the parent clocks for unused VPs to avoid conflict.
> >
> > Fixes: 6f8605fd7d11 ("arm64: dts: ti: k3-am69-sk: Add DP and HDMI support")
> > Reported-by: Nishanth Menon <[email protected]>
> > Signed-off-by: Jayesh Choudhary <[email protected]>
> > Reviewed-by: Tomi Valkeinen <[email protected]>
>
> Reviewed-by: Aradhya Bhatia <[email protected]>
>

This patch fixes the issue I see on my AM69-SK board and after
applying it the HDMI of the board works again so

Tested-by: Enric Balletbo i Serra <[email protected]>

> Regards
> Aradhya
>
> > ---
> >
> > v1: <https://lore.kernel.org/all/[email protected]/>
> >
> > Changelog v1->v2:
> > - Updated commit message
> > - Picked up Tomi's R-by from v1
> > - Removed "Closes:" link since its invalid now
> >
> > (NOTE: Sending again as forgot to put mailing list in cc earlier)
> >
> > arch/arm64/boot/dts/ti/k3-am69-sk.dts | 8 ++------
> > 1 file changed, 2 insertions(+), 6 deletions(-)
> >
> > diff --git a/arch/arm64/boot/dts/ti/k3-am69-sk.dts b/arch/arm64/boot/dts/ti/k3-am69-sk.dts
> > index 8da591579868..370980eb59b0 100644
> > --- a/arch/arm64/boot/dts/ti/k3-am69-sk.dts
> > +++ b/arch/arm64/boot/dts/ti/k3-am69-sk.dts
> > @@ -918,13 +918,9 @@ &dss {
> > pinctrl-names = "default";
> > pinctrl-0 = <&dss_vout0_pins_default>;
> > assigned-clocks = <&k3_clks 218 2>,
> > - <&k3_clks 218 5>,
> > - <&k3_clks 218 14>,
> > - <&k3_clks 218 18>;
> > + <&k3_clks 218 5>;
> > assigned-clock-parents = <&k3_clks 218 3>,
> > - <&k3_clks 218 7>,
> > - <&k3_clks 218 16>,
> > - <&k3_clks 218 22>;
> > + <&k3_clks 218 7>;
> > };
> >
> > &serdes_wiz4 {
>


2024-02-06 04:56:41

by Vignesh Raghavendra

[permalink] [raw]
Subject: Re: [RESEND PATCH v2] arm64: dts: ti: k3-am69-sk: remove assigned-clock-parents for unused VP

Hi Jayesh Choudhary,

On Thu, 01 Feb 2024 19:53:08 +0530, Jayesh Choudhary wrote:
> VP2 and VP3 are unused video ports and VP3 share the same parent
> clock as VP1 causing issue with pixel clock setting for HDMI (VP1).
> The current DM firmware does not support changing parent clock if it
> is shared by another component. It returns 0 for the determine_rate
> query before causing set_rate to set the clock at default maximum of
> 1.8GHz which is a lot more than the maximum frequency videoports can
> support (600MHz) causing SYNC LOST issues.
> So remove the parent clocks for unused VPs to avoid conflict.
>
> [...]

I have applied the following to branch ti-k3-dts-next on [1].
Thank you!

[1/1] arm64: dts: ti: k3-am69-sk: remove assigned-clock-parents for unused VP
commit: cfdb4f7ffdb855c1a3d274dc7757e780dcbf2d55

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent up the chain during
the next merge window (or sooner if it is a relevant bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

[1] https://git.kernel.org/pub/scm/linux/kernel/git/ti/linux.git
--
Vignesh