2023-01-23 15:16:45

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [PATCH] arm64: dts: tegra: drop serial clock-names and reset-names

The serial node does not use clock-names and reset-names:

tegra234-sim-vdk.dtb: serial@3100000: Unevaluated properties are not allowed ('clock-names', 'reset-names' were unexpected)

Signed-off-by: Krzysztof Kozlowski <[email protected]>
---
arch/arm64/boot/dts/nvidia/tegra132.dtsi | 8 --------
arch/arm64/boot/dts/nvidia/tegra186.dtsi | 2 --
arch/arm64/boot/dts/nvidia/tegra194.dtsi | 4 ----
arch/arm64/boot/dts/nvidia/tegra210.dtsi | 8 --------
arch/arm64/boot/dts/nvidia/tegra234.dtsi | 2 --
5 files changed, 24 deletions(-)

diff --git a/arch/arm64/boot/dts/nvidia/tegra132.dtsi b/arch/arm64/boot/dts/nvidia/tegra132.dtsi
index c017764bc27e..8b78be8f4f9d 100644
--- a/arch/arm64/boot/dts/nvidia/tegra132.dtsi
+++ b/arch/arm64/boot/dts/nvidia/tegra132.dtsi
@@ -338,9 +338,7 @@ uarta: serial@70006000 {
reg-shift = <2>;
interrupts = <GIC_SPI 36 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&tegra_car TEGRA124_CLK_UARTA>;
- clock-names = "serial";
resets = <&tegra_car 6>;
- reset-names = "serial";
dmas = <&apbdma 8>, <&apbdma 8>;
dma-names = "rx", "tx";
status = "disabled";
@@ -352,9 +350,7 @@ uartb: serial@70006040 {
reg-shift = <2>;
interrupts = <GIC_SPI 37 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&tegra_car TEGRA124_CLK_UARTB>;
- clock-names = "serial";
resets = <&tegra_car 7>;
- reset-names = "serial";
dmas = <&apbdma 9>, <&apbdma 9>;
dma-names = "rx", "tx";
status = "disabled";
@@ -366,9 +362,7 @@ uartc: serial@70006200 {
reg-shift = <2>;
interrupts = <GIC_SPI 46 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&tegra_car TEGRA124_CLK_UARTC>;
- clock-names = "serial";
resets = <&tegra_car 55>;
- reset-names = "serial";
dmas = <&apbdma 10>, <&apbdma 10>;
dma-names = "rx", "tx";
status = "disabled";
@@ -380,9 +374,7 @@ uartd: serial@70006300 {
reg-shift = <2>;
interrupts = <GIC_SPI 90 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&tegra_car TEGRA124_CLK_UARTD>;
- clock-names = "serial";
resets = <&tegra_car 65>;
- reset-names = "serial";
dmas = <&apbdma 19>, <&apbdma 19>;
dma-names = "rx", "tx";
status = "disabled";
diff --git a/arch/arm64/boot/dts/nvidia/tegra186.dtsi b/arch/arm64/boot/dts/nvidia/tegra186.dtsi
index 0216b565a370..995276ef55eb 100644
--- a/arch/arm64/boot/dts/nvidia/tegra186.dtsi
+++ b/arch/arm64/boot/dts/nvidia/tegra186.dtsi
@@ -610,9 +610,7 @@ uarta: serial@3100000 {
reg-shift = <2>;
interrupts = <GIC_SPI 112 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&bpmp TEGRA186_CLK_UARTA>;
- clock-names = "serial";
resets = <&bpmp TEGRA186_RESET_UARTA>;
- reset-names = "serial";
status = "disabled";
};

diff --git a/arch/arm64/boot/dts/nvidia/tegra194.dtsi b/arch/arm64/boot/dts/nvidia/tegra194.dtsi
index 5ce2650128b1..b9092790c811 100644
--- a/arch/arm64/boot/dts/nvidia/tegra194.dtsi
+++ b/arch/arm64/boot/dts/nvidia/tegra194.dtsi
@@ -745,9 +745,7 @@ uarta: serial@3100000 {
reg-shift = <2>;
interrupts = <GIC_SPI 112 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&bpmp TEGRA194_CLK_UARTA>;
- clock-names = "serial";
resets = <&bpmp TEGRA194_RESET_UARTA>;
- reset-names = "serial";
status = "disabled";
};

@@ -757,9 +755,7 @@ uartb: serial@3110000 {
reg-shift = <2>;
interrupts = <GIC_SPI 113 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&bpmp TEGRA194_CLK_UARTB>;
- clock-names = "serial";
resets = <&bpmp TEGRA194_RESET_UARTB>;
- reset-names = "serial";
status = "disabled";
};

diff --git a/arch/arm64/boot/dts/nvidia/tegra210.dtsi b/arch/arm64/boot/dts/nvidia/tegra210.dtsi
index 980565bf02c9..0e463b3cbe01 100644
--- a/arch/arm64/boot/dts/nvidia/tegra210.dtsi
+++ b/arch/arm64/boot/dts/nvidia/tegra210.dtsi
@@ -618,9 +618,7 @@ uarta: serial@70006000 {
reg-shift = <2>;
interrupts = <GIC_SPI 36 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&tegra_car TEGRA210_CLK_UARTA>;
- clock-names = "serial";
resets = <&tegra_car 6>;
- reset-names = "serial";
dmas = <&apbdma 8>, <&apbdma 8>;
dma-names = "rx", "tx";
status = "disabled";
@@ -632,9 +630,7 @@ uartb: serial@70006040 {
reg-shift = <2>;
interrupts = <GIC_SPI 37 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&tegra_car TEGRA210_CLK_UARTB>;
- clock-names = "serial";
resets = <&tegra_car 7>;
- reset-names = "serial";
dmas = <&apbdma 9>, <&apbdma 9>;
dma-names = "rx", "tx";
status = "disabled";
@@ -646,9 +642,7 @@ uartc: serial@70006200 {
reg-shift = <2>;
interrupts = <GIC_SPI 46 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&tegra_car TEGRA210_CLK_UARTC>;
- clock-names = "serial";
resets = <&tegra_car 55>;
- reset-names = "serial";
dmas = <&apbdma 10>, <&apbdma 10>;
dma-names = "rx", "tx";
status = "disabled";
@@ -660,9 +654,7 @@ uartd: serial@70006300 {
reg-shift = <2>;
interrupts = <GIC_SPI 90 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&tegra_car TEGRA210_CLK_UARTD>;
- clock-names = "serial";
resets = <&tegra_car 65>;
- reset-names = "serial";
dmas = <&apbdma 19>, <&apbdma 19>;
dma-names = "rx", "tx";
status = "disabled";
diff --git a/arch/arm64/boot/dts/nvidia/tegra234.dtsi b/arch/arm64/boot/dts/nvidia/tegra234.dtsi
index b54353f31df5..372be226a7f4 100644
--- a/arch/arm64/boot/dts/nvidia/tegra234.dtsi
+++ b/arch/arm64/boot/dts/nvidia/tegra234.dtsi
@@ -676,9 +676,7 @@ uarta: serial@3100000 {
reg = <0x0 0x03100000 0x0 0x10000>;
interrupts = <GIC_SPI 112 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&bpmp TEGRA234_CLK_UARTA>;
- clock-names = "serial";
resets = <&bpmp TEGRA234_RESET_UARTA>;
- reset-names = "serial";
status = "disabled";
};

--
2.34.1



2023-03-12 16:59:50

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH] arm64: dts: tegra: drop serial clock-names and reset-names

On 23/01/2023 16:15, Krzysztof Kozlowski wrote:
> The serial node does not use clock-names and reset-names:
>
> tegra234-sim-vdk.dtb: serial@3100000: Unevaluated properties are not allowed ('clock-names', 'reset-names' were unexpected)
>
> Signed-off-by: Krzysztof Kozlowski <[email protected]>

Thierry, any comments? Can you pick it up?

Best regards,
Krzysztof


2023-03-22 19:32:32

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH] arm64: dts: tegra: drop serial clock-names and reset-names

On 12/03/2023 17:59, Krzysztof Kozlowski wrote:
> On 23/01/2023 16:15, Krzysztof Kozlowski wrote:
>> The serial node does not use clock-names and reset-names:
>>
>> tegra234-sim-vdk.dtb: serial@3100000: Unevaluated properties are not allowed ('clock-names', 'reset-names' were unexpected)
>>
>> Signed-off-by: Krzysztof Kozlowski <[email protected]>
>
> Thierry, any comments? Can you pick it up?

Hm, so I guess it is for me?

Best regards,
Krzysztof

2023-03-23 08:49:11

by Thierry Reding

[permalink] [raw]
Subject: Re: [PATCH] arm64: dts: tegra: drop serial clock-names and reset-names

On Wed, Mar 22, 2023 at 08:22:45PM +0100, Krzysztof Kozlowski wrote:
> On 12/03/2023 17:59, Krzysztof Kozlowski wrote:
> > On 23/01/2023 16:15, Krzysztof Kozlowski wrote:
> >> The serial node does not use clock-names and reset-names:
> >>
> >> tegra234-sim-vdk.dtb: serial@3100000: Unevaluated properties are not allowed ('clock-names', 'reset-names' were unexpected)
> >>
> >> Signed-off-by: Krzysztof Kozlowski <[email protected]>
> >
> > Thierry, any comments? Can you pick it up?
>
> Hm, so I guess it is for me?

Sorry, been away for a couple of weeks. I'll pick this up.

Thanks,
Thierry


Attachments:
(No filename) (628.00 B)
signature.asc (849.00 B)
Download all attachments

2023-03-23 08:53:04

by Thierry Reding

[permalink] [raw]
Subject: Re: [PATCH] arm64: dts: tegra: drop serial clock-names and reset-names

From: Thierry Reding <[email protected]>

On Mon, 23 Jan 2023 16:15:43 +0100, Krzysztof Kozlowski wrote:
> The serial node does not use clock-names and reset-names:
>
> tegra234-sim-vdk.dtb: serial@3100000: Unevaluated properties are not allowed ('clock-names', 'reset-names' were unexpected)
>
>

Applied, thanks!

[1/1] arm64: dts: tegra: drop serial clock-names and reset-names
(no commit info)

Best regards,
--
Thierry Reding <[email protected]>

2023-06-28 10:29:29

by Jon Hunter

[permalink] [raw]
Subject: Re: [PATCH] arm64: dts: tegra: drop serial clock-names and reset-names


On 23/01/2023 15:15, Krzysztof Kozlowski wrote:
> The serial node does not use clock-names and reset-names:
>
> tegra234-sim-vdk.dtb: serial@3100000: Unevaluated properties are not allowed ('clock-names', 'reset-names' were unexpected)
>
> Signed-off-by: Krzysztof Kozlowski <[email protected]>
> ---
> arch/arm64/boot/dts/nvidia/tegra132.dtsi | 8 --------
> arch/arm64/boot/dts/nvidia/tegra186.dtsi | 2 --
> arch/arm64/boot/dts/nvidia/tegra194.dtsi | 4 ----
> arch/arm64/boot/dts/nvidia/tegra210.dtsi | 8 --------
> arch/arm64/boot/dts/nvidia/tegra234.dtsi | 2 --
> 5 files changed, 24 deletions(-)

...

> diff --git a/arch/arm64/boot/dts/nvidia/tegra234.dtsi b/arch/arm64/boot/dts/nvidia/tegra234.dtsi
> index b54353f31df5..372be226a7f4 100644
> --- a/arch/arm64/boot/dts/nvidia/tegra234.dtsi
> +++ b/arch/arm64/boot/dts/nvidia/tegra234.dtsi
> @@ -676,9 +676,7 @@ uarta: serial@3100000 {
> reg = <0x0 0x03100000 0x0 0x10000>;
> interrupts = <GIC_SPI 112 IRQ_TYPE_LEVEL_HIGH>;
> clocks = <&bpmp TEGRA234_CLK_UARTA>;
> - clock-names = "serial";
> resets = <&bpmp TEGRA234_RESET_UARTA>;
> - reset-names = "serial";
> status = "disabled";
> };
>


Thierry, do you have a patch to convert the Documentation/devicetree/bindings/serial/nvidia,tegra20-hsuart.txt to yaml? I have noticed that the above change now cause the hsuart to fail on Tegra234 ...

[ 5.109961] serial-tegra 3100000.serial: Couldn't get the reset
[ 5.116302] serial-tegra: probe of 3100000.serial failed with error -2

The drivers/tty/serial/serial-tegra.c driver is making the following call ...

tup->rst = devm_reset_control_get_exclusive(&pdev->dev, "serial");

May be the correct fix for this would be to populate the reset-names in ...

diff --git a/arch/arm64/boot/dts/nvidia/tegra234-p3737-0000+p3701-0000.dts b/arch/arm64/boot/dts/nvidia/tegra234-p3737-0000+p3701-0000.dts
index cd13cf2381dd..513cc2cd0b66 100644
--- a/arch/arm64/boot/dts/nvidia/tegra234-p3737-0000+p3701-0000.dts
+++ b/arch/arm64/boot/dts/nvidia/tegra234-p3737-0000+p3701-0000.dts
@@ -2010,6 +2010,7 @@ interrupt-controller@2a40000 {

serial@3100000 {
compatible = "nvidia,tegra194-hsuart";
+ reset-names = "serial";
status = "okay";
};

I can send a patch.

Jon

--
nvpublic

2023-07-01 08:36:02

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH] arm64: dts: tegra: drop serial clock-names and reset-names

On 28/06/2023 11:58, Jon Hunter wrote:
>
> On 23/01/2023 15:15, Krzysztof Kozlowski wrote:
>> The serial node does not use clock-names and reset-names:
>>
>> tegra234-sim-vdk.dtb: serial@3100000: Unevaluated properties are not allowed ('clock-names', 'reset-names' were unexpected)
>>
>> Signed-off-by: Krzysztof Kozlowski <[email protected]>
>> ---
>> arch/arm64/boot/dts/nvidia/tegra132.dtsi | 8 --------
>> arch/arm64/boot/dts/nvidia/tegra186.dtsi | 2 --
>> arch/arm64/boot/dts/nvidia/tegra194.dtsi | 4 ----
>> arch/arm64/boot/dts/nvidia/tegra210.dtsi | 8 --------
>> arch/arm64/boot/dts/nvidia/tegra234.dtsi | 2 --
>> 5 files changed, 24 deletions(-)
>
> ...
>
>> diff --git a/arch/arm64/boot/dts/nvidia/tegra234.dtsi b/arch/arm64/boot/dts/nvidia/tegra234.dtsi
>> index b54353f31df5..372be226a7f4 100644
>> --- a/arch/arm64/boot/dts/nvidia/tegra234.dtsi
>> +++ b/arch/arm64/boot/dts/nvidia/tegra234.dtsi
>> @@ -676,9 +676,7 @@ uarta: serial@3100000 {
>> reg = <0x0 0x03100000 0x0 0x10000>;
>> interrupts = <GIC_SPI 112 IRQ_TYPE_LEVEL_HIGH>;
>> clocks = <&bpmp TEGRA234_CLK_UARTA>;
>> - clock-names = "serial";
>> resets = <&bpmp TEGRA234_RESET_UARTA>;
>> - reset-names = "serial";
>> status = "disabled";
>> };
>>
>
>
> Thierry, do you have a patch to convert the Documentation/devicetree/bindings/serial/nvidia,tegra20-hsuart.txt to yaml? I have noticed that the above change now cause the hsuart to fail on Tegra234 ...

my patch was touching only the UART (8250), not the HSUART. These are
different compatible and different drivers. Why do you think HSUART is
affected here?

Best regards,
Krzysztof


2023-07-03 10:05:19

by Jon Hunter

[permalink] [raw]
Subject: Re: [PATCH] arm64: dts: tegra: drop serial clock-names and reset-names


On 01/07/2023 09:14, Krzysztof Kozlowski wrote:
> On 28/06/2023 11:58, Jon Hunter wrote:
>>
>> On 23/01/2023 15:15, Krzysztof Kozlowski wrote:
>>> The serial node does not use clock-names and reset-names:
>>>
>>> tegra234-sim-vdk.dtb: serial@3100000: Unevaluated properties are not allowed ('clock-names', 'reset-names' were unexpected)
>>>
>>> Signed-off-by: Krzysztof Kozlowski <[email protected]>
>>> ---
>>> arch/arm64/boot/dts/nvidia/tegra132.dtsi | 8 --------
>>> arch/arm64/boot/dts/nvidia/tegra186.dtsi | 2 --
>>> arch/arm64/boot/dts/nvidia/tegra194.dtsi | 4 ----
>>> arch/arm64/boot/dts/nvidia/tegra210.dtsi | 8 --------
>>> arch/arm64/boot/dts/nvidia/tegra234.dtsi | 2 --
>>> 5 files changed, 24 deletions(-)
>>
>> ...
>>
>>> diff --git a/arch/arm64/boot/dts/nvidia/tegra234.dtsi b/arch/arm64/boot/dts/nvidia/tegra234.dtsi
>>> index b54353f31df5..372be226a7f4 100644
>>> --- a/arch/arm64/boot/dts/nvidia/tegra234.dtsi
>>> +++ b/arch/arm64/boot/dts/nvidia/tegra234.dtsi
>>> @@ -676,9 +676,7 @@ uarta: serial@3100000 {
>>> reg = <0x0 0x03100000 0x0 0x10000>;
>>> interrupts = <GIC_SPI 112 IRQ_TYPE_LEVEL_HIGH>;
>>> clocks = <&bpmp TEGRA234_CLK_UARTA>;
>>> - clock-names = "serial";
>>> resets = <&bpmp TEGRA234_RESET_UARTA>;
>>> - reset-names = "serial";
>>> status = "disabled";
>>> };
>>>
>>
>>
>> Thierry, do you have a patch to convert the Documentation/devicetree/bindings/serial/nvidia,tegra20-hsuart.txt to yaml? I have noticed that the above change now cause the hsuart to fail on Tegra234 ...
>
> my patch was touching only the UART (8250), not the HSUART. These are
> different compatible and different drivers. Why do you think HSUART is
> affected here?

Yes they are completely different and your patch is obviously correct.
However, for the Jetson AGX Orin board we update the compatible string
to use the HSUART driver (in
arch/arm64/boot/dts/nvidia/tegra234-p3737-0000+p3701-0000.dts) and here
we don't add the necessary reset name which we should.

I was just flagging this issue to Thierry. I will send a fix for this.

Jon

--
nvpublic