ARM: dts: meson: add the AO ARC remote processor
authorMartin Blumenstingl <martin.blumenstingl@googlemail.com>
Sat, 2 Jan 2021 20:59:04 +0000 (21:59 +0100)
committerKevin Hilman <khilman@baylibre.com>
Wed, 3 Feb 2021 18:22:10 +0000 (10:22 -0800)
The 32-bit Amlogic Meson SoCs embed an ARC processor in the Always-On
power domain which is typically used for managing system suspend. The
memory for this ARC core is taken from the AHB SRAM area. Depending on
the actual SoC a different ARC core is used:
- Meson6 and earlier: some ARCv1 ISA based core (probably an ARC625)
- Meson8 and later: an ARC EM4 (ARCv2 ISA) based core

Add the device-tree node for this remote-processor along with the
required SRAM sections, clocks and reset-lines. Also use the
SoC-specific compatible string to manage any differences (should
they exist).

On Meson8, Meson8b and Meson8m2 the "secbus2" IO region is needed as
some bits need to be programmed there. Add this IO region for those
SoCs as well.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20210102205904.2691120-6-martin.blumenstingl@googlemail.com
arch/arm/boot/dts/meson.dtsi
arch/arm/boot/dts/meson8.dtsi
arch/arm/boot/dts/meson8b.dtsi

index 7649dd1e0b9ee5cd6aa67d0a8ef48a3f80e08a84..21ecf3335852ec64af4f3e3270c142a3aae578ab 100644 (file)
                        #size-cells = <1>;
                        ranges = <0x0 0xc8100000 0x100000>;
 
+                       ao_arc_rproc: remoteproc@1c {
+                               compatible= "amlogic,meson-mx-ao-arc";
+                               reg = <0x1c 0x8>, <0x38 0x8>;
+                               reg-names = "remap", "cpu";
+                               status = "disabled";
+                       };
+
                        ir_receiver: ir-receiver@480 {
                                compatible= "amlogic,meson6-ir";
                                reg = <0x480 0x20>;
index 04688e8abce2c386d2cdb59d69011ab9b1943f29..93f09b5d1503880e76795a9dfd451b73c516d73d 100644 (file)
        };
 };
 
+&ao_arc_rproc {
+       compatible= "amlogic,meson8-ao-arc", "amlogic,meson-mx-ao-arc";
+       amlogic,secbus2 = <&secbus2>;
+       sram = <&ao_arc_sram>;
+       resets = <&reset RESET_MEDIA_CPU>;
+       clocks = <&clkc CLKID_AO_MEDIA_CPU>;
+};
+
 &cbus {
        reset: reset-controller@4404 {
                compatible = "amlogic,meson8b-reset";
 };
 
 &ahb_sram {
+       ao_arc_sram: ao-arc-sram@0 {
+               compatible = "amlogic,meson8-ao-arc-sram";
+               reg = <0x0 0x8000>;
+               pool;
+       };
+
        smp-sram@1ff80 {
                compatible = "amlogic,meson8-smp-sram";
                reg = <0x1ff80 0x8>;
        clock-names = "clkin0", "clkin1", "clkin2", "clkin3", "pclk";
 };
 
+&secbus {
+       secbus2: system-controller@4000 {
+               compatible = "amlogic,meson8-secbus2", "syscon";
+               reg = <0x4000 0x2000>;
+       };
+};
+
 &sdio {
        compatible = "amlogic,meson8-sdio", "amlogic,meson-mx-sdio";
        clocks = <&clkc CLKID_SDIO>, <&clkc CLKID_CLK81>;
index 2401cdf5f7511be3bd16e4b77db46e3e88f7152f..a285c34aef94ba3c5e47c20006848faccdfa68af 100644 (file)
        };
 };
 
+&ao_arc_rproc {
+       compatible= "amlogic,meson8b-ao-arc", "amlogic,meson-mx-ao-arc";
+       amlogic,secbus2 = <&secbus2>;
+       sram = <&ao_arc_sram>;
+       resets = <&reset RESET_MEDIA_CPU>;
+       clocks = <&clkc CLKID_AO_MEDIA_CPU>;
+};
+
 &cbus {
        reset: reset-controller@4404 {
                compatible = "amlogic,meson8b-reset";
 };
 
 &ahb_sram {
+       ao_arc_sram: ao-arc-sram@0 {
+               compatible = "amlogic,meson8b-ao-arc-sram";
+               reg = <0x0 0x8000>;
+               pool;
+       };
+
        smp-sram@1ff80 {
                compatible = "amlogic,meson8b-smp-sram";
                reg = <0x1ff80 0x8>;
        clock-names = "clkin0", "clkin1", "clkin2", "clkin3", "pclk";
 };
 
+&secbus {
+       secbus2: system-controller@4000 {
+               compatible = "amlogic,meson8b-secbus2", "syscon";
+               reg = <0x4000 0x2000>;
+       };
+};
+
 &sdio {
        compatible = "amlogic,meson8b-sdio", "amlogic,meson-mx-sdio";
        clocks = <&clkc CLKID_SDIO>, <&clkc CLKID_CLK81>;