diff mbox series

[1/3] arm64: dts: meson-g12a: Add IR nodes

Message ID 20190412100518.24470-2-narmstrong@baylibre.com (mailing list archive)
State Mainlined
Commit 2bfe8412c5388a0a3122a1b51a7969a0dec72171
Headers show
Series arm64: meson-g12a: Add Infrared Decoder support | expand

Commit Message

Neil Armstrong April 12, 2019, 10:05 a.m. UTC
Amlogic G12A SoCs uses the exact same IR decoder as previous
families, add the IR node and the pintctrl setting.

Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
---
 arch/arm64/boot/dts/amlogic/meson-g12a.dtsi | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

Comments

Martin Blumenstingl April 13, 2019, 12:02 p.m. UTC | #1
Hi Neil,

On Fri, Apr 12, 2019 at 12:05 PM Neil Armstrong <narmstrong@baylibre.com> wrote:
>
> Amlogic G12A SoCs uses the exact same IR decoder as previous
> families, add the IR node and the pintctrl setting.
as far as I can tell there are either two IR decoders or one updated
IR decoder in G12A and G12B.
I'm using mesong12a.dtsi from
buildroot_openlinux_kernel_4.9_fbdev_20180706 as reference:
  remote:rc@0xff808040 {
      compatible = "amlogic, aml_remote";
      reg = <0x0 0xff808040 0x00 0x44>, /*Multi-format IR controller*/
                <0x0 0xff808000 0x00 0x20>; /*Legacy IR controller*/
      ...

the registers which you are mapping are for the "Legacy IR
controller", so our existing meson-ir driver will probably work (I
haven't tested it myself yet).

can you please be explicit about this in the patch description?

> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
apart from the description you can add my:
Reviewed-by: Martin Blumenstingl<martin.blumenstingl@googlemail.com>
Neil Armstrong April 23, 2019, 8:30 a.m. UTC | #2
Hi Martin,

On 13/04/2019 14:02, Martin Blumenstingl wrote:
> Hi Neil,
> 
> On Fri, Apr 12, 2019 at 12:05 PM Neil Armstrong <narmstrong@baylibre.com> wrote:
>>
>> Amlogic G12A SoCs uses the exact same IR decoder as previous
>> families, add the IR node and the pintctrl setting.
> as far as I can tell there are either two IR decoders or one updated
> IR decoder in G12A and G12B.
> I'm using mesong12a.dtsi from
> buildroot_openlinux_kernel_4.9_fbdev_20180706 as reference:
>   remote:rc@0xff808040 {
>       compatible = "amlogic, aml_remote";
>       reg = <0x0 0xff808040 0x00 0x44>, /*Multi-format IR controller*/
>                 <0x0 0xff808000 0x00 0x20>; /*Legacy IR controller*/
>       ...
> 
> the registers which you are mapping are for the "Legacy IR
> controller", so our existing meson-ir driver will probably work (I
> haven't tested it myself yet).

We use only the "legacy IR decoder" since GXBB, we never had a driver for
the "Multi-format IR controller".

> 
> can you please be explicit about this in the patch description?

Sure

> 
>> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
> apart from the description you can add my:
> Reviewed-by: Martin Blumenstingl<martin.blumenstingl@googlemail.com>
> 

Thanks,
Neil
Kevin Hilman May 8, 2019, 11:05 p.m. UTC | #3
Neil Armstrong <narmstrong@baylibre.com> writes:

> Amlogic G12A SoCs uses the exact same IR decoder as previous
> families, add the IR node and the pintctrl setting.
>
> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
> ---
>  arch/arm64/boot/dts/amlogic/meson-g12a.dtsi | 14 ++++++++++++++
>  1 file changed, 14 insertions(+)
>
> diff --git a/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi b/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi
> index 734c5ee60efa..9cb76d325bb7 100644
> --- a/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi
> +++ b/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi
> @@ -559,6 +559,13 @@
>  						mux {
>  							groups = "pwm_ao_d_e";
>  							function = "pwm_ao_d";
> +						};
> +					};

nit: you had applied this based on top of the PWM series, but didn't
mention that in the cover letter.

Kevin

> +					remote_input_ao_pins: remote-input-ao {
> +						mux {
> +							groups = "remote_ao_input";
> +							function = "remote_ao_input";
>  							bias-disable;
>  						};
>  					};
> @@ -623,6 +630,13 @@
>  				status = "disabled";
>  			};
>  
> +			ir: ir@8000 {
> +				compatible = "amlogic,meson-gxbb-ir";
> +				reg = <0x0 0x8000 0x0 0x20>;
> +				interrupts = <GIC_SPI 196 IRQ_TYPE_EDGE_RISING>;
> +				status = "disabled";
> +			};
> +
>  			saradc: adc@9000 {
>  				compatible = "amlogic,meson-g12a-saradc",
>  					     "amlogic,meson-saradc";
> -- 
> 2.21.0
diff mbox series

Patch

diff --git a/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi b/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi
index 734c5ee60efa..9cb76d325bb7 100644
--- a/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi
+++ b/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi
@@ -559,6 +559,13 @@ 
 						mux {
 							groups = "pwm_ao_d_e";
 							function = "pwm_ao_d";
+						};
+					};
+
+					remote_input_ao_pins: remote-input-ao {
+						mux {
+							groups = "remote_ao_input";
+							function = "remote_ao_input";
 							bias-disable;
 						};
 					};
@@ -623,6 +630,13 @@ 
 				status = "disabled";
 			};
 
+			ir: ir@8000 {
+				compatible = "amlogic,meson-gxbb-ir";
+				reg = <0x0 0x8000 0x0 0x20>;
+				interrupts = <GIC_SPI 196 IRQ_TYPE_EDGE_RISING>;
+				status = "disabled";
+			};
+
 			saradc: adc@9000 {
 				compatible = "amlogic,meson-g12a-saradc",
 					     "amlogic,meson-saradc";