[RFC 3/3] dts: beaglebone: Portable connector BB_RELAY_4PORT definition

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




Example of a portable connector port for the BB_RELAY_4PORT cape

Signed-off-by: Pantelis Antoniou <pantelis.antoniou@xxxxxxxxxxxx>
---
 arch/arm/boot/dts/am335x-bone-common.dtsi | 48 +++++++++++++++++++++++++++++++
 1 file changed, 48 insertions(+)

diff --git a/arch/arm/boot/dts/am335x-bone-common.dtsi b/arch/arm/boot/dts/am335x-bone-common.dtsi
index 0e73ab6..06f2191 100644
--- a/arch/arm/boot/dts/am335x-bone-common.dtsi
+++ b/arch/arm/boot/dts/am335x-bone-common.dtsi
@@ -2045,6 +2045,54 @@
 			compatible = "simple-bus";
 			#address-cells = <1>;
 			#size-cells = <0>;
+
+			BB_RELAY_4PORT {
+				compatible = "simple-bus";
+				#address-cells = <1>;
+				#size-cells = <0>;
+
+				gpio_relay_4port: gpio_relay_4port@0 {
+					compatible = "dtcon-gpio";
+					status = "okay";
+
+					gpio-controller;
+					#gpio-cells = <2>;
+
+					pin-list = <9 15>,	/* #0 P9.15 */
+						   <9 23>,	/* #1 P9.23 */
+						   <9 12>,	/* #2 P9.12 */
+						   <9 27>;	/* #3 P9.27 */
+				};
+
+				leds@0 {
+					compatible = "gpio-leds";
+					status = "okay";
+
+					jp@1 {
+						label = "relay-jp1";
+						gpios = <&gpio_relay_4port 0 GPIO_ACTIVE_HIGH>;
+						default-state = "keep";
+					};
+
+					jp@2 {
+						label = "relay-jp2";
+						gpios = <&gpio_relay_4port 1 GPIO_ACTIVE_HIGH>;
+						default-state = "keep";
+					};
+
+					jp@3 {
+						label = "relay-jp3";
+						gpios = <&gpio_relay_4port 2 GPIO_ACTIVE_HIGH>;
+						default-state = "keep";
+					};
+
+					jp@4 {
+						label = "relay-jp4";
+						gpios = <&gpio_relay_4port 3 GPIO_ACTIVE_HIGH>;
+						default-state = "keep";
+					};
+				};
+			};
 		};
 	};
 };
-- 
1.7.12

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]
  Powered by Linux