arm64: dts: stratix10: add gpio header
Subsystems (2)
PATCH 1/2 arm64: dts: stratix10: add gpio header
Add the gpio header to the base stratix10 dtsi.
Signed-off-by Alan Tull <[email protected]>
--- arch/arm64/boot/dts/altera/socfpga_stratix10.dtsi | 1 + 1 file changed, 1 insertion(+)
arch/arm64/boot/dts/altera/socfpga_stratix10.dtsi +1 -0
@@ -16,6 +16,7 @@ /dts-v1/; #include <dt-bindings/reset/altr,rst-mgr-s10.h> +#include <dt-bindings/gpio/gpio.h> / { compatible = "altr,socfpga-stratix10";
Signature · 1 line
2.7.4
PATCH 2/2 arm64: dts: stratix10: enable gpio and leds
Enable gpio and leds for socdk OOBE daughtercard.
pushbutton PB_SW0 = gpio1.io4
pushbutton PB_SW1 = gpio1.io5
LED HPS_LED0 = gpio1.io20 LED HPS_LED1 = gpio1.io19 LED HPS_LED2 = gpio1.io21
Signed-off-by Alan Tull <[email protected]>
--- .../boot/dts/altera/socfpga_stratix10_socdk.dts | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+)
arch/arm64/boot/dts/altera/socfpga_stratix10_socdk.dts +22 -0
@@ -27,6 +27,24 @@ stdout-path = "serial0:115200n8"; }; + leds { + compatible = "gpio-leds"; + hps0 { + label = "hps_led0"; + gpios = <&portb 20 GPIO_ACTIVE_HIGH>; + }; + + hps1 { + label = "hps_led1"; + gpios = <&portb 19 GPIO_ACTIVE_HIGH>; + }; + + hps2 { + label = "hps_led2"; + gpios = <&portb 21 GPIO_ACTIVE_HIGH>; + }; + }; + memory { device_type = "memory"; /* We expect the bootloader to fill in the reg */
@@ -34,6 +52,10 @@ }; }; +&gpio1 { + status = "okay"; +}; + &gmac0 { status = "okay"; phy-mode = "rgmii";
Signature · 1 line
2.7.4
Dinh Nguyen
maintainerRe: [PATCH 2/2] arm64: dts: stratix10: enable gpio and leds
Quoted 4 lines · Alan Tull
Enable gpio and leds for socdk OOBE daughtercard.
pushbutton
PB_SW0= gpio1.io4
pushbuttonPB_SW1= gpio1.io5
Quoted 9 lines
LED HPS_LED0 = gpio1.io20 LED HPS_LED1 = gpio1.io19 LED HPS_LED2 = gpio1.io21Signed-off-by Alan Tull <[email protected]>--- .../boot/dts/altera/socfpga_stratix10_socdk.dts | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+)
Both patches applied, thanks Alan!
Dinh