* [PATCH v5 0/4] tty/serial: meson_uart: add support for core clock handling @ 2017-06-14 8:29 Neil Armstrong 2017-06-14 8:29 ` [PATCH v5 3/4] ARM64: dts: meson-gx: use stable UART bindings with correct gate clock Neil Armstrong ` (2 more replies) 0 siblings, 3 replies; 9+ messages in thread From: Neil Armstrong @ 2017-06-14 8:29 UTC (permalink / raw) To: gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r, khilman-rdvid1DuHRBWk0Htik3J/w Cc: Neil Armstrong, hgkr.klein-Re5JQEeQqe8AvxtiuMwx3w, linux-serial-u79uwXL29TY76Z2rM5mHXA, linux-amlogic-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, linux-kernel-u79uwXL29TY76Z2rM5mHXA, devicetree-u79uwXL29TY76Z2rM5mHXA This patchset is a re-spin of Helmut Klein's v3 patchset at [0] and the v4 patchset at [1]. Initially, the original patchset was made to enable usage on the non-AO UARTS not enabled by the Bootloader (uart_B and uart_C), but the patchset needed an overall change to have clean and stable DT bindings. The Amlogic Meson UART Driver did not have stable DT bindings and mismatched clock handling on non-AO UARTs since these "EE" UARTs needs a clock gate to be ungated to works correctly. In the same way, the AO UARTs does not need gating and can be used as Early Consoles. In the same time, the UART Interfaces can take clock input for the baudrate generate from either the external Xtal or the internal Bus Clock (clk81). So new bindings was necessary to meet these requirements and the DT maintainers requirements. The "legacy" binding actually used in the driver is left until all the DT files are switched to the new bindings. The GX DT has been tested, but the last 4 Meson6/Meson8/b are only compile-tested, and testing is welcome. Thus only the first 3 patches can be merged until the Meson6/Meson8/b are formally tested. It must be noted that the meson6 cannot work today except using an early console since the UART driver could not probe without a clocks property. Changes since v4 at [1]: - Droped meson8/meson8b DT patches - Fixes copy/paste error in patch 2 - Refactored clock probing in patch 2 - merged meson6 patches together to avoid breaking bisect [0] http://lkml.kernel.org/r/20170331165437.26227-1-hgkr.klein-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org [1] http://lkml.kernel.org/r/1497001756-942-1-git-send-email-narmstrong-rdvid1DuHRBWk0Htik3J/w@public.gmane.org Helmut Klein (3): dt-bindings: serial: Add bindings for the Amlogic Meson UARTs tty/serial: meson_uart: update to stable bindings ARM64: dts: meson-gx: use stable UART bindings with correct gate clock Neil Armstrong (1): ARM: dts: meson6: use stable UART bindings .../bindings/serial/amlogic,meson-uart.txt | 38 +++++++++ arch/arm/boot/dts/meson.dtsi | 8 +- arch/arm/boot/dts/meson6.dtsi | 28 +++++++ arch/arm64/boot/dts/amlogic/meson-gx.dtsi | 12 ++- arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi | 25 ++++++ arch/arm64/boot/dts/amlogic/meson-gxl.dtsi | 25 ++++++ drivers/tty/serial/meson_uart.c | 90 ++++++++++++++++++++-- 7 files changed, 209 insertions(+), 17 deletions(-) create mode 100644 Documentation/devicetree/bindings/serial/amlogic,meson-uart.txt -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH v5 3/4] ARM64: dts: meson-gx: use stable UART bindings with correct gate clock 2017-06-14 8:29 [PATCH v5 0/4] tty/serial: meson_uart: add support for core clock handling Neil Armstrong @ 2017-06-14 8:29 ` Neil Armstrong 2017-06-16 20:57 ` Kevin Hilman [not found] ` <1497428957-19942-1-git-send-email-narmstrong-rdvid1DuHRBWk0Htik3J/w@public.gmane.org> 2017-06-19 8:43 ` [PATCH v5 0/4] tty/serial: meson_uart: add support for core clock handling Neil Armstrong 2 siblings, 1 reply; 9+ messages in thread From: Neil Armstrong @ 2017-06-14 8:29 UTC (permalink / raw) To: gregkh, khilman Cc: Helmut Klein, linux-serial, linux-amlogic, linux-arm-kernel, linux-kernel, devicetree, Neil Armstrong From: Helmut Klein <hgkr.klein@gmail.com> This patch switches to the stable UART bindings but also add the correct gate clock to the non-AO UART nodes for GXBB and GXL SoCs. Acked-by: Jerome Brunet <jbrunet@baylibre.com> Signed-off-by: Helmut Klein <hgkr.klein@gmail.com> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> --- arch/arm64/boot/dts/amlogic/meson-gx.dtsi | 12 +++++------- arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi | 25 +++++++++++++++++++++++++ arch/arm64/boot/dts/amlogic/meson-gxl.dtsi | 25 +++++++++++++++++++++++++ 3 files changed, 55 insertions(+), 7 deletions(-) diff --git a/arch/arm64/boot/dts/amlogic/meson-gx.dtsi b/arch/arm64/boot/dts/amlogic/meson-gx.dtsi index 603491d..86a4018 100644 --- a/arch/arm64/boot/dts/amlogic/meson-gx.dtsi +++ b/arch/arm64/boot/dts/amlogic/meson-gx.dtsi @@ -225,7 +225,7 @@ }; uart_A: serial@84c0 { - compatible = "amlogic,meson-uart"; + compatible = "amlogic,meson-gx-uart"; reg = <0x0 0x84c0 0x0 0x14>; interrupts = <GIC_SPI 26 IRQ_TYPE_EDGE_RISING>; clocks = <&xtal>; @@ -233,7 +233,7 @@ }; uart_B: serial@84dc { - compatible = "amlogic,meson-uart"; + compatible = "amlogic,meson-gx-uart"; reg = <0x0 0x84dc 0x0 0x14>; interrupts = <GIC_SPI 75 IRQ_TYPE_EDGE_RISING>; clocks = <&xtal>; @@ -279,7 +279,7 @@ }; uart_C: serial@8700 { - compatible = "amlogic,meson-uart"; + compatible = "amlogic,meson-gx-uart"; reg = <0x0 0x8700 0x0 0x14>; interrupts = <GIC_SPI 93 IRQ_TYPE_EDGE_RISING>; clocks = <&xtal>; @@ -366,18 +366,16 @@ }; uart_AO: serial@4c0 { - compatible = "amlogic,meson-uart"; + compatible = "amlogic,meson-gx-uart", "amlogic,meson-ao-uart"; reg = <0x0 0x004c0 0x0 0x14>; interrupts = <GIC_SPI 193 IRQ_TYPE_EDGE_RISING>; - clocks = <&xtal>; status = "disabled"; }; uart_AO_B: serial@4e0 { - compatible = "amlogic,meson-uart"; + compatible = "amlogic,meson-gx-uart", "amlogic,meson-ao-uart"; reg = <0x0 0x004e0 0x0 0x14>; interrupts = <GIC_SPI 197 IRQ_TYPE_EDGE_RISING>; - clocks = <&xtal>; status = "disabled"; }; diff --git a/arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi b/arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi index dbd300f..1ae8da7 100644 --- a/arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi +++ b/arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi @@ -675,6 +675,31 @@ clocks = <&clkc CLKID_SPI>; }; +&uart_A { + clocks = <&xtal>, <&clkc CLKID_UART0>, <&xtal>; + clock-names = "xtal", "pclk", "baud"; +}; + +&uart_AO { + clocks = <&xtal>, <&clkc CLKID_CLK81>, <&xtal>; + clock-names = "xtal", "pclk", "baud"; +}; + +&uart_AO_B { + clocks = <&xtal>, <&clkc CLKID_CLK81>, <&xtal>; + clock-names = "xtal", "pclk", "baud"; +}; + +&uart_B { + clocks = <&xtal>, <&clkc CLKID_UART1>, <&xtal>; + clock-names = "xtal", "core", "baud"; +}; + +&uart_C { + clocks = <&xtal>, <&clkc CLKID_UART2>, <&xtal>; + clock-names = "xtal", "core", "baud"; +}; + &vpu { compatible = "amlogic,meson-gxbb-vpu", "amlogic,meson-gx-vpu"; }; diff --git a/arch/arm64/boot/dts/amlogic/meson-gxl.dtsi b/arch/arm64/boot/dts/amlogic/meson-gxl.dtsi index 4dfc22b..0c601f8 100644 --- a/arch/arm64/boot/dts/amlogic/meson-gxl.dtsi +++ b/arch/arm64/boot/dts/amlogic/meson-gxl.dtsi @@ -616,6 +616,31 @@ clocks = <&clkc CLKID_SPI>; }; +&uart_A { + clocks = <&xtal>, <&clkc CLKID_UART0>, <&xtal>; + clock-names = "xtal", "core", "baud"; +}; + +&uart_AO { + clocks = <&xtal>, <&clkc CLKID_CLK81>, <&xtal>; + clock-names = "xtal", "pclk", "baud"; +}; + +&uart_AO_B { + clocks = <&xtal>, <&clkc CLKID_CLK81>, <&xtal>; + clock-names = "xtal", "pclk", "baud"; +}; + +&uart_B { + clocks = <&xtal>, <&clkc CLKID_UART1>, <&xtal>; + clock-names = "xtal", "core", "baud"; +}; + +&uart_C { + clocks = <&xtal>, <&clkc CLKID_UART2>, <&xtal>; + clock-names = "xtal", "core", "baud"; +}; + &vpu { compatible = "amlogic,meson-gxl-vpu", "amlogic,meson-gx-vpu"; }; -- 1.9.1 ^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH v5 3/4] ARM64: dts: meson-gx: use stable UART bindings with correct gate clock 2017-06-14 8:29 ` [PATCH v5 3/4] ARM64: dts: meson-gx: use stable UART bindings with correct gate clock Neil Armstrong @ 2017-06-16 20:57 ` Kevin Hilman 2017-06-19 8:40 ` Neil Armstrong 0 siblings, 1 reply; 9+ messages in thread From: Kevin Hilman @ 2017-06-16 20:57 UTC (permalink / raw) To: Neil Armstrong Cc: gregkh, Helmut Klein, linux-serial, linux-amlogic, linux-arm-kernel, linux-kernel, devicetree Neil Armstrong <narmstrong@baylibre.com> writes: > From: Helmut Klein <hgkr.klein@gmail.com> > > This patch switches to the stable UART bindings but also add the correct > gate clock to the non-AO UART nodes for GXBB and GXL SoCs. > > Acked-by: Jerome Brunet <jbrunet@baylibre.com> > Signed-off-by: Helmut Klein <hgkr.klein@gmail.com> > Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> > --- > arch/arm64/boot/dts/amlogic/meson-gx.dtsi | 12 +++++------- > arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi | 25 +++++++++++++++++++++++++ > arch/arm64/boot/dts/amlogic/meson-gxl.dtsi | 25 +++++++++++++++++++++++++ > 3 files changed, 55 insertions(+), 7 deletions(-) > > diff --git a/arch/arm64/boot/dts/amlogic/meson-gx.dtsi b/arch/arm64/boot/dts/amlogic/meson-gx.dtsi > index 603491d..86a4018 100644 > --- a/arch/arm64/boot/dts/amlogic/meson-gx.dtsi > +++ b/arch/arm64/boot/dts/amlogic/meson-gx.dtsi > @@ -225,7 +225,7 @@ > }; > > uart_A: serial@84c0 { > - compatible = "amlogic,meson-uart"; > + compatible = "amlogic,meson-gx-uart"; IMO, we should keep both compatibles (the more specific one first.) That would allow new DTs to continue to run on older kernels. It would also allow this DT change to be completely independent of the driver changes. Otherwise, if I merge this before the driver change are merged, we'll have a bunch of boards with no more serial console output. Kevin ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v5 3/4] ARM64: dts: meson-gx: use stable UART bindings with correct gate clock 2017-06-16 20:57 ` Kevin Hilman @ 2017-06-19 8:40 ` Neil Armstrong 0 siblings, 0 replies; 9+ messages in thread From: Neil Armstrong @ 2017-06-19 8:40 UTC (permalink / raw) To: Kevin Hilman Cc: gregkh, Helmut Klein, linux-serial, linux-amlogic, linux-arm-kernel, linux-kernel, devicetree On 06/16/2017 10:57 PM, Kevin Hilman wrote: > Neil Armstrong <narmstrong@baylibre.com> writes: > >> From: Helmut Klein <hgkr.klein@gmail.com> >> >> This patch switches to the stable UART bindings but also add the correct >> gate clock to the non-AO UART nodes for GXBB and GXL SoCs. >> >> Acked-by: Jerome Brunet <jbrunet@baylibre.com> >> Signed-off-by: Helmut Klein <hgkr.klein@gmail.com> >> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> >> --- >> arch/arm64/boot/dts/amlogic/meson-gx.dtsi | 12 +++++------- >> arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi | 25 +++++++++++++++++++++++++ >> arch/arm64/boot/dts/amlogic/meson-gxl.dtsi | 25 +++++++++++++++++++++++++ >> 3 files changed, 55 insertions(+), 7 deletions(-) >> >> diff --git a/arch/arm64/boot/dts/amlogic/meson-gx.dtsi b/arch/arm64/boot/dts/amlogic/meson-gx.dtsi >> index 603491d..86a4018 100644 >> --- a/arch/arm64/boot/dts/amlogic/meson-gx.dtsi >> +++ b/arch/arm64/boot/dts/amlogic/meson-gx.dtsi >> @@ -225,7 +225,7 @@ >> }; >> >> uart_A: serial@84c0 { >> - compatible = "amlogic,meson-uart"; >> + compatible = "amlogic,meson-gx-uart"; > > IMO, we should keep both compatibles (the more specific one first.) > That would allow new DTs to continue to run on older kernels. > > It would also allow this DT change to be completely independent of the > driver changes. Otherwise, if I merge this before the driver change are > merged, we'll have a bunch of boards with no more serial console output. > > Kevin > Hi Kevin, Sure, no problem with that. I'll push an update when the bindings + tty fixes are merged somewhere. Neil ^ permalink raw reply [flat|nested] 9+ messages in thread
[parent not found: <1497428957-19942-1-git-send-email-narmstrong-rdvid1DuHRBWk0Htik3J/w@public.gmane.org>]
* [PATCH v5 1/4] dt-bindings: serial: Add bindings for the Amlogic Meson UARTs [not found] ` <1497428957-19942-1-git-send-email-narmstrong-rdvid1DuHRBWk0Htik3J/w@public.gmane.org> @ 2017-06-14 8:29 ` Neil Armstrong 2017-06-18 14:05 ` Rob Herring 2017-06-14 8:29 ` [PATCH v5 4/4] ARM: dts: meson6: use stable UART bindings Neil Armstrong 1 sibling, 1 reply; 9+ messages in thread From: Neil Armstrong @ 2017-06-14 8:29 UTC (permalink / raw) To: gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r, khilman-rdvid1DuHRBWk0Htik3J/w Cc: Helmut Klein, linux-serial-u79uwXL29TY76Z2rM5mHXA, linux-amlogic-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, linux-kernel-u79uwXL29TY76Z2rM5mHXA, devicetree-u79uwXL29TY76Z2rM5mHXA, Neil Armstrong From: Helmut Klein <hgkr.klein-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> Add the documentation for the device tree binding of Amlogic Meson Serial UART. Signed-off-by: Helmut Klein <hgkr.klein-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> Signed-off-by: Neil Armstrong <narmstrong-rdvid1DuHRBWk0Htik3J/w@public.gmane.org> --- .../bindings/serial/amlogic,meson-uart.txt | 38 ++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 Documentation/devicetree/bindings/serial/amlogic,meson-uart.txt diff --git a/Documentation/devicetree/bindings/serial/amlogic,meson-uart.txt b/Documentation/devicetree/bindings/serial/amlogic,meson-uart.txt new file mode 100644 index 0000000..8ff65fa --- /dev/null +++ b/Documentation/devicetree/bindings/serial/amlogic,meson-uart.txt @@ -0,0 +1,38 @@ +Amlogic Meson SoC UART Serial Interface +======================================= + +The Amlogic Meson SoC UART Serial Interface is present on a large range +of SoCs, and can be present either in the "Always-On" power domain or the +"Everything-Else" power domain. + +The particularity of the "Always-On" Serial Interface is that the hardware +is active since power-on and does not need any clock gating and is usable +as very early serial console. + +Required properties: +- compatible : compatible: value should be different for each SoC family as : + - Meson6 : "amlogic,meson6-uart" + - Meson8 : "amlogic,meson8-uart" + - Meson8b : "amlogic,meson8b-uart" + - GX (GXBB, GXL, GXM) : "amlogic,meson-gx-uart" + eventually followed by : "amlogic,meson-ao-uart" if this UART interface + is in the "Always-On" power domain. +- reg : offset and length of the register set for the device. +- interrupts : identifier to the device interrupt +- clocks : a list of phandle + clock-specifier pairs, one for each + entry in clock names. +- clocks-names : + * "xtal" for external xtal clock identifier + * "pclk" for the bus core clock, either the clk81 clock or the gate clock + * "baud" for the source of the baudrate generator, can be either the xtal + or the pclk. + +e.g. +uart_A: serial@84c0 { + compatible = "amlogic,meson-gx-uart"; + reg = <0x0 0x84c0 0x0 0x14>; + interrupts = <GIC_SPI 26 IRQ_TYPE_EDGE_RISING>; + /* Use xtal as baud rate clock source */ + clocks = <&xtal>, <&clkc CLKID_UART0>, <&xtal>; + clock-names = "xtal", "pclk", "baud"; +}; -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH v5 1/4] dt-bindings: serial: Add bindings for the Amlogic Meson UARTs 2017-06-14 8:29 ` [PATCH v5 1/4] dt-bindings: serial: Add bindings for the Amlogic Meson UARTs Neil Armstrong @ 2017-06-18 14:05 ` Rob Herring 0 siblings, 0 replies; 9+ messages in thread From: Rob Herring @ 2017-06-18 14:05 UTC (permalink / raw) To: Neil Armstrong Cc: gregkh, khilman, Helmut Klein, linux-serial, linux-amlogic, linux-arm-kernel, linux-kernel, devicetree On Wed, Jun 14, 2017 at 10:29:14AM +0200, Neil Armstrong wrote: > From: Helmut Klein <hgkr.klein@gmail.com> > > Add the documentation for the device tree binding of Amlogic Meson Serial UART. > > Signed-off-by: Helmut Klein <hgkr.klein@gmail.com> > Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> > --- > .../bindings/serial/amlogic,meson-uart.txt | 38 ++++++++++++++++++++++ > 1 file changed, 38 insertions(+) > create mode 100644 Documentation/devicetree/bindings/serial/amlogic,meson-uart.txt Acked-by: Rob Herring <robh@kernel.org> ^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH v5 4/4] ARM: dts: meson6: use stable UART bindings [not found] ` <1497428957-19942-1-git-send-email-narmstrong-rdvid1DuHRBWk0Htik3J/w@public.gmane.org> 2017-06-14 8:29 ` [PATCH v5 1/4] dt-bindings: serial: Add bindings for the Amlogic Meson UARTs Neil Armstrong @ 2017-06-14 8:29 ` Neil Armstrong 1 sibling, 0 replies; 9+ messages in thread From: Neil Armstrong @ 2017-06-14 8:29 UTC (permalink / raw) To: gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r, khilman-rdvid1DuHRBWk0Htik3J/w Cc: Neil Armstrong, hgkr.klein-Re5JQEeQqe8AvxtiuMwx3w, linux-serial-u79uwXL29TY76Z2rM5mHXA, linux-amlogic-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, linux-kernel-u79uwXL29TY76Z2rM5mHXA, devicetree-u79uwXL29TY76Z2rM5mHXA The UART bindings needs specifying a SoC family, use the meson6 family for the UART nodes like the other nodes. Switch to the stable UART bindings for meson6 by adding a XTAL node and using the proper compatible strings. Signed-off-by: Neil Armstrong <narmstrong-rdvid1DuHRBWk0Htik3J/w@public.gmane.org> --- arch/arm/boot/dts/meson.dtsi | 8 ++++---- arch/arm/boot/dts/meson6.dtsi | 28 ++++++++++++++++++++++++++++ 2 files changed, 32 insertions(+), 4 deletions(-) diff --git a/arch/arm/boot/dts/meson.dtsi b/arch/arm/boot/dts/meson.dtsi index 8d9c369..ecc9330 100644 --- a/arch/arm/boot/dts/meson.dtsi +++ b/arch/arm/boot/dts/meson.dtsi @@ -79,14 +79,14 @@ ranges = <0x0 0xc1100000 0x200000>; uart_A: serial@84c0 { - compatible = "amlogic,meson-uart"; + compatible = "amlogic,meson6-uart"; reg = <0x84c0 0x18>; interrupts = <0 26 1>; status = "disabled"; }; uart_B: serial@84dc { - compatible = "amlogic,meson-uart"; + compatible = "amlogic,meson6-uart"; reg = <0x84dc 0x18>; interrupts = <0 75 1>; status = "disabled"; @@ -102,7 +102,7 @@ }; uart_C: serial@8700 { - compatible = "amlogic,meson-uart"; + compatible = "amlogic,meson6-uart"; reg = <0x8700 0x18>; interrupts = <0 93 1>; status = "disabled"; @@ -153,7 +153,7 @@ }; uart_AO: serial@4c0 { - compatible = "amlogic,meson-uart"; + compatible = "amlogic,meson6-uart", "amlogic,meson-ao-uart"; reg = <0x4c0 0x18>; interrupts = <0 90 1>; status = "disabled"; diff --git a/arch/arm/boot/dts/meson6.dtsi b/arch/arm/boot/dts/meson6.dtsi index b0fc91f..a334fbe 100644 --- a/arch/arm/boot/dts/meson6.dtsi +++ b/arch/arm/boot/dts/meson6.dtsi @@ -70,9 +70,37 @@ }; }; + xtal: xtal-clk { + compatible = "fixed-clock"; + clock-frequency = <24000000>; + clock-output-names = "xtal"; + #clock-cells = <0>; + }; + clk81: clk@0 { #clock-cells = <0>; compatible = "fixed-clock"; clock-frequency = <200000000>; }; }; /* end of / */ + + +&uart_AO { + clocks = <&xtal>, <&clk81>, <&clk81>; + clock-names = "xtal", "pclk", "baud"; +}; + +&uart_A { + clocks = <&xtal>, <&clk81>, <&clk81>; + clock-names = "xtal", "pclk", "baud"; +}; + +&uart_B { + clocks = <&xtal>, <&clk81>, <&clk81>; + clock-names = "xtal", "pclk", "baud"; +}; + +&uart_C { + clocks = <&xtal>, <&clk81>, <&clk81>; + clock-names = "xtal", "pclk", "baud"; +}; -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH v5 0/4] tty/serial: meson_uart: add support for core clock handling 2017-06-14 8:29 [PATCH v5 0/4] tty/serial: meson_uart: add support for core clock handling Neil Armstrong 2017-06-14 8:29 ` [PATCH v5 3/4] ARM64: dts: meson-gx: use stable UART bindings with correct gate clock Neil Armstrong [not found] ` <1497428957-19942-1-git-send-email-narmstrong-rdvid1DuHRBWk0Htik3J/w@public.gmane.org> @ 2017-06-19 8:43 ` Neil Armstrong [not found] ` <f4179b26-54fc-30ee-2d8d-7659349ccb74-rdvid1DuHRBWk0Htik3J/w@public.gmane.org> 2 siblings, 1 reply; 9+ messages in thread From: Neil Armstrong @ 2017-06-19 8:43 UTC (permalink / raw) To: gregkh, khilman Cc: hgkr.klein, linux-serial, linux-amlogic, linux-arm-kernel, linux-kernel, devicetree On 06/14/2017 10:29 AM, Neil Armstrong wrote: > This patchset is a re-spin of Helmut Klein's v3 patchset at [0] and the v4 patchset at [1]. > > Initially, the original patchset was made to enable usage on the non-AO UARTS > not enabled by the Bootloader (uart_B and uart_C), but the patchset needed > an overall change to have clean and stable DT bindings. > > The Amlogic Meson UART Driver did not have stable DT bindings and mismatched > clock handling on non-AO UARTs since these "EE" UARTs needs a clock gate to > be ungated to works correctly. > In the same way, the AO UARTs does not need gating and can be used as > Early Consoles. > > In the same time, the UART Interfaces can take clock input for the baudrate > generate from either the external Xtal or the internal Bus Clock (clk81). > > So new bindings was necessary to meet these requirements and the DT > maintainers requirements. > > The "legacy" binding actually used in the driver is left until all the DT > files are switched to the new bindings. > > The GX DT has been tested, but the last 4 Meson6/Meson8/b are only > compile-tested, and testing is welcome. > Thus only the first 3 patches can be merged until the Meson6/Meson8/b are > formally tested. > > It must be noted that the meson6 cannot work today except using an early > console since the UART driver could not probe without a clocks property. > > Changes since v4 at [1]: > - Droped meson8/meson8b DT patches > - Fixes copy/paste error in patch 2 > - Refactored clock probing in patch 2 > - merged meson6 patches together to avoid breaking bisect > > [0] http://lkml.kernel.org/r/20170331165437.26227-1-hgkr.klein@gmail.com > [1] http://lkml.kernel.org/r/1497001756-942-1-git-send-email-narmstrong@baylibre.com > > Helmut Klein (3): > dt-bindings: serial: Add bindings for the Amlogic Meson UARTs > tty/serial: meson_uart: update to stable bindings > ARM64: dts: meson-gx: use stable UART bindings with correct gate clock > > Neil Armstrong (1): > ARM: dts: meson6: use stable UART bindings > > .../bindings/serial/amlogic,meson-uart.txt | 38 +++++++++ > arch/arm/boot/dts/meson.dtsi | 8 +- > arch/arm/boot/dts/meson6.dtsi | 28 +++++++ > arch/arm64/boot/dts/amlogic/meson-gx.dtsi | 12 ++- > arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi | 25 ++++++ > arch/arm64/boot/dts/amlogic/meson-gxl.dtsi | 25 ++++++ > drivers/tty/serial/meson_uart.c | 90 ++++++++++++++++++++-- > 7 files changed, 209 insertions(+), 17 deletions(-) > create mode 100644 Documentation/devicetree/bindings/serial/amlogic,meson-uart.txt > Hi Greg, Patches 3 & 4 will need a respin to avoid breaking compatibility with old kernel like the tty patch does by keeping the legacy compatible string. I will re-send then in a separate thread and Kevin will handle them. Patches 1 & 2 can be taken if they are OK for you. Thanks, Neil ^ permalink raw reply [flat|nested] 9+ messages in thread
[parent not found: <f4179b26-54fc-30ee-2d8d-7659349ccb74-rdvid1DuHRBWk0Htik3J/w@public.gmane.org>]
* Re: [PATCH v5 0/4] tty/serial: meson_uart: add support for core clock handling [not found] ` <f4179b26-54fc-30ee-2d8d-7659349ccb74-rdvid1DuHRBWk0Htik3J/w@public.gmane.org> @ 2017-06-20 2:51 ` Greg KH 0 siblings, 0 replies; 9+ messages in thread From: Greg KH @ 2017-06-20 2:51 UTC (permalink / raw) To: Neil Armstrong Cc: khilman-rdvid1DuHRBWk0Htik3J/w, hgkr.klein-Re5JQEeQqe8AvxtiuMwx3w, linux-serial-u79uwXL29TY76Z2rM5mHXA, linux-amlogic-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, linux-kernel-u79uwXL29TY76Z2rM5mHXA, devicetree-u79uwXL29TY76Z2rM5mHXA On Mon, Jun 19, 2017 at 10:43:05AM +0200, Neil Armstrong wrote: > On 06/14/2017 10:29 AM, Neil Armstrong wrote: > > This patchset is a re-spin of Helmut Klein's v3 patchset at [0] and the v4 patchset at [1]. > > > > Initially, the original patchset was made to enable usage on the non-AO UARTS > > not enabled by the Bootloader (uart_B and uart_C), but the patchset needed > > an overall change to have clean and stable DT bindings. > > > > The Amlogic Meson UART Driver did not have stable DT bindings and mismatched > > clock handling on non-AO UARTs since these "EE" UARTs needs a clock gate to > > be ungated to works correctly. > > In the same way, the AO UARTs does not need gating and can be used as > > Early Consoles. > > > > In the same time, the UART Interfaces can take clock input for the baudrate > > generate from either the external Xtal or the internal Bus Clock (clk81). > > > > So new bindings was necessary to meet these requirements and the DT > > maintainers requirements. > > > > The "legacy" binding actually used in the driver is left until all the DT > > files are switched to the new bindings. > > > > The GX DT has been tested, but the last 4 Meson6/Meson8/b are only > > compile-tested, and testing is welcome. > > Thus only the first 3 patches can be merged until the Meson6/Meson8/b are > > formally tested. > > > > It must be noted that the meson6 cannot work today except using an early > > console since the UART driver could not probe without a clocks property. > > > > Changes since v4 at [1]: > > - Droped meson8/meson8b DT patches > > - Fixes copy/paste error in patch 2 > > - Refactored clock probing in patch 2 > > - merged meson6 patches together to avoid breaking bisect > > > > [0] http://lkml.kernel.org/r/20170331165437.26227-1-hgkr.klein-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org > > [1] http://lkml.kernel.org/r/1497001756-942-1-git-send-email-narmstrong-rdvid1DuHRBWk0Htik3J/w@public.gmane.org > > > > Helmut Klein (3): > > dt-bindings: serial: Add bindings for the Amlogic Meson UARTs > > tty/serial: meson_uart: update to stable bindings > > ARM64: dts: meson-gx: use stable UART bindings with correct gate clock > > > > Neil Armstrong (1): > > ARM: dts: meson6: use stable UART bindings > > > > .../bindings/serial/amlogic,meson-uart.txt | 38 +++++++++ > > arch/arm/boot/dts/meson.dtsi | 8 +- > > arch/arm/boot/dts/meson6.dtsi | 28 +++++++ > > arch/arm64/boot/dts/amlogic/meson-gx.dtsi | 12 ++- > > arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi | 25 ++++++ > > arch/arm64/boot/dts/amlogic/meson-gxl.dtsi | 25 ++++++ > > drivers/tty/serial/meson_uart.c | 90 ++++++++++++++++++++-- > > 7 files changed, 209 insertions(+), 17 deletions(-) > > create mode 100644 Documentation/devicetree/bindings/serial/amlogic,meson-uart.txt > > > > > Hi Greg, > > Patches 3 & 4 will need a respin to avoid breaking compatibility with old kernel > like the tty patch does by keeping the legacy compatible string. > I will re-send then in a separate thread and Kevin will handle them. > > Patches 1 & 2 can be taken if they are OK for you. Looks good, now applied, thanks. Feel free to resend the other two whenever you have them ready. greg k-h -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2017-06-20 2:51 UTC | newest] Thread overview: 9+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2017-06-14 8:29 [PATCH v5 0/4] tty/serial: meson_uart: add support for core clock handling Neil Armstrong 2017-06-14 8:29 ` [PATCH v5 3/4] ARM64: dts: meson-gx: use stable UART bindings with correct gate clock Neil Armstrong 2017-06-16 20:57 ` Kevin Hilman 2017-06-19 8:40 ` Neil Armstrong [not found] ` <1497428957-19942-1-git-send-email-narmstrong-rdvid1DuHRBWk0Htik3J/w@public.gmane.org> 2017-06-14 8:29 ` [PATCH v5 1/4] dt-bindings: serial: Add bindings for the Amlogic Meson UARTs Neil Armstrong 2017-06-18 14:05 ` Rob Herring 2017-06-14 8:29 ` [PATCH v5 4/4] ARM: dts: meson6: use stable UART bindings Neil Armstrong 2017-06-19 8:43 ` [PATCH v5 0/4] tty/serial: meson_uart: add support for core clock handling Neil Armstrong [not found] ` <f4179b26-54fc-30ee-2d8d-7659349ccb74-rdvid1DuHRBWk0Htik3J/w@public.gmane.org> 2017-06-20 2:51 ` Greg KH
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).