add Meson8/Meson8b serial core clock handling
Subsystems (2)
Martin Blumenstingl
reviewerv2 cover add Meson8/Meson8b serial core clock handling
This patchset adds the tty/serial core clock handling to the UARTs on Meson8 and Meson8b.
Basically this is the Meson8 and Meson8b version of a patchset from Helmut Klein and Neil Armstrong, who implemented this for Meson GX (see [0]). Back then I asked Neil to drop Meson8b from his patchset because I was working on the Meson8 clock controller at that time.
This also removes the last users that rely on the "amlogic,meson-uart" binding. Removing that binding from the meson_uart driver is not part of this series though.
changes since v1 at [1]:
- moved the "baud" clock to the first position because the meson_uart driver currently chooses the first clock as baud clock (this is until the legacy clock handling is removed from the driver). in v1 the xtal clock was the first clock, which means that (other than before) the xtal clock was used to generate the baudrate.
- added Jerome's Acked-by (thank you!)
[0] http://lists.infradead.org/pipermail/linux-amlogic/2017-June/004173.html
[1] http://lists.infradead.org/pipermail/linux-amlogic/2017-October/005144.html
Martin Blumenstingl (2):
ARM: dts: meson8: use stable UART bindings with correct gate clock
ARM: dts: meson8b: use stable UART bindings with correct gate clock
arch/arm/boot/dts/meson8.dtsi | 16 ++++++++++++---- arch/arm/boot/dts/meson8b.dtsi | 16 ++++++++++++---- 2 files changed, 24 insertions(+), 8 deletions(-)
Signature · 1 line
2.15.0
Martin Blumenstingl
reviewerPATCH v2 1/2 ARM: dts: meson8: use stable UART bindings with correct gate clock
Switch to the stable UART bindings and add the correct gate clocks to the non-AO UART nodes.
This fixes the non-AO UARTs if the bootloader didn't un-gate the clocks.
--- arch/arm/boot/dts/meson8.dtsi | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-)
arch/arm/boot/dts/meson8.dtsi +12 -4
@@ -337,19 +337,27 @@ }; &uart_AO { - clocks = <&clkc CLKID_CLK81>; + compatible = "amlogic,meson8-uart", "amlogic,meson-uart"; + clocks = <&clkc CLKID_CLK81>, <&clkc CLKID_XTAL>, <&clkc CLKID_CLK81>; + clock-names = "baud", "xtal", "pclk"; }; &uart_A { - clocks = <&clkc CLKID_CLK81>; + compatible = "amlogic,meson8-uart", "amlogic,meson-uart"; + clocks = <&clkc CLKID_CLK81>, <&clkc CLKID_XTAL>, <&clkc CLKID_UART0>; + clock-names = "baud", "xtal", "pclk"; }; &uart_B { - clocks = <&clkc CLKID_CLK81>; + compatible = "amlogic,meson8-uart", "amlogic,meson-uart"; + clocks = <&clkc CLKID_CLK81>, <&clkc CLKID_XTAL>, <&clkc CLKID_UART1>; + clock-names = "baud", "xtal", "pclk"; }; &uart_C { - clocks = <&clkc CLKID_CLK81>; + compatible = "amlogic,meson8-uart", "amlogic,meson-uart"; + clocks = <&clkc CLKID_CLK81>, <&clkc CLKID_XTAL>, <&clkc CLKID_UART2>; + clock-names = "baud", "xtal", "pclk"; }; &usb0 {
Signature · 1 line
2.15.0
Martin Blumenstingl
reviewerPATCH v2 2/2 ARM: dts: meson8b: use stable UART bindings with correct gate clock
In reply to Martin BlumenstinglSwitch to the stable UART bindings and add the correct gate clocks to the non-AO UART nodes.
This fixes the non-AO UARTs if the bootloader didn't un-gate the clocks.
--- arch/arm/boot/dts/meson8b.dtsi | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-)
arch/arm/boot/dts/meson8b.dtsi +12 -4
@@ -248,19 +248,27 @@ }; &uart_AO { - clocks = <&clkc CLKID_CLK81>; + compatible = "amlogic,meson8b-uart", "amlogic,meson-uart"; + clocks = <&clkc CLKID_CLK81>, <&clkc CLKID_XTAL>, <&clkc CLKID_CLK81>; + clock-names = "baud", "xtal", "pclk"; }; &uart_A { - clocks = <&clkc CLKID_CLK81>; + compatible = "amlogic,meson8b-uart", "amlogic,meson-uart"; + clocks = <&clkc CLKID_CLK81>, <&clkc CLKID_XTAL>, <&clkc CLKID_UART0>; + clock-names = "baud", "xtal", "pclk"; }; &uart_B { - clocks = <&clkc CLKID_CLK81>; + compatible = "amlogic,meson8b-uart", "amlogic,meson-uart"; + clocks = <&clkc CLKID_CLK81>, <&clkc CLKID_XTAL>, <&clkc CLKID_UART1>; + clock-names = "baud", "xtal", "pclk"; }; &uart_C { - clocks = <&clkc CLKID_CLK81>; + compatible = "amlogic,meson8b-uart", "amlogic,meson-uart"; + clocks = <&clkc CLKID_CLK81>, <&clkc CLKID_XTAL>, <&clkc CLKID_UART2>; + clock-names = "baud", "xtal", "pclk"; }; &usb0 {
Signature · 1 line
2.15.0
Kevin Hilman
maintainerv2 cover add Meson8/Meson8b serial core clock handling
In reply to Martin BlumenstinglQuoted 11 lines · Martin Blumenstingl
This patchset adds the tty/serial core clock handling to the UARTs on Meson8 and Meson8b.
Basically this is the Meson8 and Meson8b version of a patchset from Helmut Klein and Neil Armstrong, who implemented this for Meson GX (see [0]). Back then I asked Neil to drop Meson8b from his patchset because I was working on the Meson8 clock controller at that time.
This also removes the last users that rely on the "amlogic,meson-uart" binding. Removing that binding from the
meson_uartdriver is not part of this series though.
I mistakenly replied to the v1 of this series. It's this version (v2) that I applied to v4.16/dt.
Sorry for the confusion, and thanks for the patches!
Kevin