* [RFC] Inconsistent sifive,fu540-c000-uart binding.
@ 2024-03-04 10:59 Sebastian Andrzej Siewior
2024-03-04 18:53 ` Conor Dooley
0 siblings, 1 reply; 3+ messages in thread
From: Sebastian Andrzej Siewior @ 2024-03-04 10:59 UTC (permalink / raw)
To: linux-riscv
Cc: Samuel Holland, Paul Walmsley, devicetree, linux-serial,
Thomas Gleixner
| $ git grep fu540-c000-uart
| Documentation/devicetree/bindings/serial/sifive-serial.yaml: - sifive,fu540-c000-uart
| Documentation/devicetree/bindings/serial/sifive-serial.yaml: compatible = "sifive,fu540-c000-uart", "sifive,uart0";
| Documentation/devicetree/bindings/sifive/sifive-blocks-ip-versioning.txt:"sifive,fu540-c000-uart". This way, if SoC-specific
| Documentation/devicetree/bindings/sifive/sifive-blocks-ip-versioning.txt: compatible = "sifive,fu540-c000-uart", "sifive,uart0";
| arch/riscv/boot/dts/sifive/fu540-c000.dtsi: compatible = "sifive,fu540-c000-uart", "sifive,uart0";
| arch/riscv/boot/dts/sifive/fu540-c000.dtsi: compatible = "sifive,fu540-c000-uart", "sifive,uart0";
| drivers/tty/serial/sifive.c:OF_EARLYCON_DECLARE(sifive, "sifive,fu540-c000-uart0",
| drivers/tty/serial/sifive.c: { .compatible = "sifive,fu540-c000-uart0" },
note that the driver has a trailing 0 in the binding while the yaml
description and the DT part does not.
The 'sifive,uart' has a trailing 0 where the 0 denotes the version UART
IP.
Was this also intended for the fu540-c000-uart binding? Should the 0 be
added everywhere or removed from the driver?
Sebastian
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [RFC] Inconsistent sifive,fu540-c000-uart binding.
2024-03-04 10:59 [RFC] Inconsistent sifive,fu540-c000-uart binding Sebastian Andrzej Siewior
@ 2024-03-04 18:53 ` Conor Dooley
2024-03-07 2:48 ` Paul Walmsley
0 siblings, 1 reply; 3+ messages in thread
From: Conor Dooley @ 2024-03-04 18:53 UTC (permalink / raw)
To: Sebastian Andrzej Siewior
Cc: linux-riscv, Samuel Holland, Paul Walmsley, devicetree,
linux-serial, Thomas Gleixner
[-- Attachment #1: Type: text/plain, Size: 1579 bytes --]
On Mon, Mar 04, 2024 at 11:59:47AM +0100, Sebastian Andrzej Siewior wrote:
> | $ git grep fu540-c000-uart
> | Documentation/devicetree/bindings/serial/sifive-serial.yaml: - sifive,fu540-c000-uart
> | Documentation/devicetree/bindings/serial/sifive-serial.yaml: compatible = "sifive,fu540-c000-uart", "sifive,uart0";
> | Documentation/devicetree/bindings/sifive/sifive-blocks-ip-versioning.txt:"sifive,fu540-c000-uart". This way, if SoC-specific
> | Documentation/devicetree/bindings/sifive/sifive-blocks-ip-versioning.txt: compatible = "sifive,fu540-c000-uart", "sifive,uart0";
> | arch/riscv/boot/dts/sifive/fu540-c000.dtsi: compatible = "sifive,fu540-c000-uart", "sifive,uart0";
> | arch/riscv/boot/dts/sifive/fu540-c000.dtsi: compatible = "sifive,fu540-c000-uart", "sifive,uart0";
> | drivers/tty/serial/sifive.c:OF_EARLYCON_DECLARE(sifive, "sifive,fu540-c000-uart0",
> | drivers/tty/serial/sifive.c: { .compatible = "sifive,fu540-c000-uart0" },
>
> note that the driver has a trailing 0 in the binding while the yaml
> description and the DT part does not.
> The 'sifive,uart' has a trailing 0 where the 0 denotes the version UART
> IP.
>
> Was this also intended for the fu540-c000-uart binding? Should the 0 be
> added everywhere or removed from the driver?
I suspect that the driver is what's incorrect, given there's little
value in putting the IP version in the SoC-specific compatible as it's
a fixed implementation. I'd change the driver to match the bindings.
Cheers,
Conor.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [RFC] Inconsistent sifive,fu540-c000-uart binding.
2024-03-04 18:53 ` Conor Dooley
@ 2024-03-07 2:48 ` Paul Walmsley
0 siblings, 0 replies; 3+ messages in thread
From: Paul Walmsley @ 2024-03-07 2:48 UTC (permalink / raw)
To: Conor Dooley
Cc: Sebastian Andrzej Siewior, linux-riscv, Samuel Holland,
devicetree, linux-serial, Thomas Gleixner
On Mon, 4 Mar 2024, Conor Dooley wrote:
> On Mon, Mar 04, 2024 at 11:59:47AM +0100, Sebastian Andrzej Siewior wrote:
> > | $ git grep fu540-c000-uart
> > | Documentation/devicetree/bindings/serial/sifive-serial.yaml: - sifive,fu540-c000-uart
> > | Documentation/devicetree/bindings/serial/sifive-serial.yaml: compatible = "sifive,fu540-c000-uart", "sifive,uart0";
> > | Documentation/devicetree/bindings/sifive/sifive-blocks-ip-versioning.txt:"sifive,fu540-c000-uart". This way, if SoC-specific
> > | Documentation/devicetree/bindings/sifive/sifive-blocks-ip-versioning.txt: compatible = "sifive,fu540-c000-uart", "sifive,uart0";
> > | arch/riscv/boot/dts/sifive/fu540-c000.dtsi: compatible = "sifive,fu540-c000-uart", "sifive,uart0";
> > | arch/riscv/boot/dts/sifive/fu540-c000.dtsi: compatible = "sifive,fu540-c000-uart", "sifive,uart0";
> > | drivers/tty/serial/sifive.c:OF_EARLYCON_DECLARE(sifive, "sifive,fu540-c000-uart0",
> > | drivers/tty/serial/sifive.c: { .compatible = "sifive,fu540-c000-uart0" },
> >
> > note that the driver has a trailing 0 in the binding while the yaml
> > description and the DT part does not.
> > The 'sifive,uart' has a trailing 0 where the 0 denotes the version UART
> > IP.
> >
> > Was this also intended for the fu540-c000-uart binding? Should the 0 be
> > added everywhere or removed from the driver?
>
> I suspect that the driver is what's incorrect, given there's little
> value in putting the IP version in the SoC-specific compatible as it's
> a fixed implementation. I'd change the driver to match the bindings.
Agreed
- Paul
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-03-07 2:48 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-04 10:59 [RFC] Inconsistent sifive,fu540-c000-uart binding Sebastian Andrzej Siewior
2024-03-04 18:53 ` Conor Dooley
2024-03-07 2:48 ` Paul Walmsley
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox