[PATCH 3/3] LoongArch: dts: Add GPIO controller for Loongson 2K0300
From: Yao Zi
Date: Fri Aug 15 2025 - 23:53:52 EST
Describe Loongson 2K0300's GPIO controller in devicetree.
Signed-off-by: Yao Zi <ziyao@xxxxxxxxxxx>
---
arch/loongarch/boot/dts/loongson-2k0300.dtsi | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/arch/loongarch/boot/dts/loongson-2k0300.dtsi b/arch/loongarch/boot/dts/loongson-2k0300.dtsi
index 835d3c63537b..60a055b05c44 100644
--- a/arch/loongarch/boot/dts/loongson-2k0300.dtsi
+++ b/arch/loongarch/boot/dts/loongson-2k0300.dtsi
@@ -240,6 +240,26 @@ uart9: serial@16102400 {
status = "disabled";
};
+ gpio: gpio@16104000 {
+ compatible = "loongson,ls2k0300-gpio";
+ reg = <0x0 0x16104000 0x0 0x4000>;
+ interrupt-parent = <&liointc1>;
+ interrupts = <21 IRQ_TYPE_LEVEL_HIGH>,
+ <22 IRQ_TYPE_LEVEL_HIGH>,
+ <23 IRQ_TYPE_LEVEL_HIGH>,
+ <24 IRQ_TYPE_LEVEL_HIGH>,
+ <25 IRQ_TYPE_LEVEL_HIGH>,
+ <26 IRQ_TYPE_LEVEL_HIGH>,
+ <27 IRQ_TYPE_LEVEL_HIGH>;
+ ngpios = <106>;
+ gpio-controller;
+ gpio-ranges = <&pinctrl 0 0 106>;
+ #gpio-cells = <2>;
+ interrupt-controller;
+ #interrupt-cells = <2>;
+ resets = <&rst RST_GPIO>;
+ };
+
isa@16400000 {
compatible = "isa";
#address-cells = <2>;
--
2.50.1