]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
riscv: dts: allwinner: d1: Add LED controller node
authorSamuel Holland <samuel@sholland.org>
Sun, 29 Oct 2023 21:26:58 +0000 (16:26 -0500)
committerChen-Yu Tsai <wens@kernel.org>
Tue, 13 Jan 2026 16:40:33 +0000 (00:40 +0800)
Allwinner D1 contains an LED controller. Add its devicetree node, as
well as the pinmux used by the reference board design.

Acked-by: Guo Ren <guoren@kernel.org>
Reviewed-by: Jernej Skrabec <jernej.skrabec@gmail.com>
Tested-by: Trevor Woerner <twoerner@gmail.com>
Signed-off-by: Samuel Holland <samuel@sholland.org>
Link: https://patch.msgid.link/20231029212738.7871-5-samuel@sholland.org
[wens@kernel.org: move "status" to end of properties]
Signed-off-by: Chen-Yu Tsai <wens@kernel.org>
arch/riscv/boot/dts/allwinner/sun20i-d1.dtsi
arch/riscv/boot/dts/allwinner/sunxi-d1s-t113.dtsi

index b18f368e06e07fa57560745f370a8230565f8061..b0fb0ea377bcaf9054ed4145fb7383236c2b8906 100644 (file)
                function = "i2c2";
        };
 
+       /omit-if-no-ref/
+       ledc_pc0_pin: ledc-pc0-pin {
+               pins = "PC0";
+               function = "ledc";
+       };
+
        /omit-if-no-ref/
        uart0_pb8_pins: uart0-pb8-pins {
                pins = "PB8", "PB9";
index 63e252b44973fa5eaf360f8a7185ad02f76315b2..895b89a83e752e8a9b514416ec054d9eb47ac982 100644 (file)
                        #reset-cells = <1>;
                };
 
+               ledc: led-controller@2008000 {
+                       compatible = "allwinner,sun20i-d1-ledc",
+                                    "allwinner,sun50i-a100-ledc";
+                       reg = <0x2008000 0x400>;
+                       interrupts = <SOC_PERIPHERAL_IRQ(20) IRQ_TYPE_LEVEL_HIGH>;
+                       clocks = <&ccu CLK_BUS_LEDC>, <&ccu CLK_LEDC>;
+                       clock-names = "bus", "mod";
+                       resets = <&ccu RST_BUS_LEDC>;
+                       dmas = <&dma 42>;
+                       dma-names = "tx";
+                       #address-cells = <1>;
+                       #size-cells = <0>;
+                       status = "disabled";
+               };
+
                gpadc: adc@2009000 {
                        compatible = "allwinner,sun20i-d1-gpadc";
                        reg = <0x2009000 0x400>;