Skip to content

Commit

Permalink
riscv: dts: Add DT support for SiFive FU540 GPIO driver
Browse files Browse the repository at this point in the history
Add the gpio DT node in SiFive FU540 soc-specific DT file.
Enable the gpio node in HiFive Unleashed board-specific DT file.

Signed-off-by: Yash Shah <yash.shah@sifive.com>
Signed-off-by: Palmer Dabbelt <palmerdabbelt@google.com>
  • Loading branch information
Yash Shah authored and Palmer Dabbelt committed Jan 29, 2020
1 parent 6435f77 commit 61ffb9d
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
15 changes: 14 additions & 1 deletion arch/riscv/boot/dts/sifive/fu540-c000.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,19 @@
interrupts = <1 2 3>;
reg = <0x0 0x2010000 0x0 0x1000>;
};

gpio: gpio@10060000 {
compatible = "sifive,fu540-c000-gpio", "sifive,gpio0";
interrupt-parent = <&plic0>;
interrupts = <7>, <8>, <9>, <10>, <11>, <12>, <13>,
<14>, <15>, <16>, <17>, <18>, <19>, <20>,
<21>, <22>;
reg = <0x0 0x10060000 0x0 0x1000>;
gpio-controller;
#gpio-cells = <2>;
interrupt-controller;
#interrupt-cells = <2>;
clocks = <&prci PRCI_CLK_TLCLK>;
status = "disabled";
};
};
};
4 changes: 4 additions & 0 deletions arch/riscv/boot/dts/sifive/hifive-unleashed-a00.dts
Original file line number Diff line number Diff line change
Expand Up @@ -94,3 +94,7 @@
&pwm1 {
status = "okay";
};

&gpio {
status = "okay";
};

0 comments on commit 61ffb9d

Please sign in to comment.