[PATCH 2/4] riscv: dts: spacemit: k3: Use Pin Macro

From: Yixun Lan

Date: Wed Nov 25 2026 - 02:47:39 EST


Use Macro for the GPIO Pin definition, which match enumeration from
pinctrl driver and make people easy to grep for debugging purpose.

Signed-off-by: Yixun Lan <dlan@xxxxxxxxxx>
---
arch/riscv/boot/dts/spacemit/k3-com260.dtsi | 2 +-
arch/riscv/boot/dts/spacemit/k3-pico-itx.dts | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/riscv/boot/dts/spacemit/k3-com260.dtsi b/arch/riscv/boot/dts/spacemit/k3-com260.dtsi
index d8e94d538bf1..65c6f49f8591 100644
--- a/arch/riscv/boot/dts/spacemit/k3-com260.dtsi
+++ b/arch/riscv/boot/dts/spacemit/k3-com260.dtsi
@@ -228,7 +228,7 @@ mdio {
phy1: ethernet-phy@1 {
compatible = "ethernet-phy-id001c.c916";
reg = <1>;
- reset-gpios = <&gpio 1 5 GPIO_ACTIVE_LOW>;
+ reset-gpios = <&gpio K3_GPIO(37) GPIO_ACTIVE_LOW>;
reset-assert-us = <10000>;
reset-deassert-us = <50000>;
};
diff --git a/arch/riscv/boot/dts/spacemit/k3-pico-itx.dts b/arch/riscv/boot/dts/spacemit/k3-pico-itx.dts
index a4afe24130ae..a74e76ee75e4 100644
--- a/arch/riscv/boot/dts/spacemit/k3-pico-itx.dts
+++ b/arch/riscv/boot/dts/spacemit/k3-pico-itx.dts
@@ -48,14 +48,14 @@ rfkill-pcie-wlan {
compatible = "rfkill-gpio";
label = "rfkill-pcie-wlan";
radio-type = "wlan";
- shutdown-gpios = <&gpio 1 3 GPIO_ACTIVE_HIGH>;
+ shutdown-gpios = <&gpio K3_GPIO(35) GPIO_ACTIVE_HIGH>;
};

rfkill-usb-bt {
compatible = "rfkill-gpio";
label = "rfkill-usb-bt";
radio-type = "bluetooth";
- shutdown-gpios = <&gpio 0 30 GPIO_ACTIVE_HIGH>;
+ shutdown-gpios = <&gpio K3_GPIO(30) GPIO_ACTIVE_HIGH>;
};
};

@@ -250,7 +250,7 @@ mdio {
phy0: ethernet-phy@1 {
compatible = "ethernet-phy-id001c.c916";
reg = <1>;
- reset-gpios = <&gpio 0 15 GPIO_ACTIVE_LOW>;
+ reset-gpios = <&gpio K3_GPIO(15) GPIO_ACTIVE_LOW>;
reset-assert-us = <10000>;
reset-deassert-us = <50000>;
realtek,aldps-enable;

--
2.56.0