Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1413456 > unrolled thread

[RFC 0/3] Portable Device Tree Connector

Started byPantelis Antoniou <pantelis.antoniou@konsulko.com>
First post2016-06-03 22:40 +0200
Last post2016-06-03 22:40 +0200
Articles 2 — 1 participant

Back to article view | Back to linux.kernel


Contents

  [RFC 0/3] Portable Device Tree Connector Pantelis Antoniou <pantelis.antoniou@konsulko.com> - 2016-06-03 22:40 +0200
    [RFC 3/3] dts: beaglebone: Portable connector BB_RELAY_4PORT definition Pantelis Antoniou <pantelis.antoniou@konsulko.com> - 2016-06-03 22:40 +0200

#1413456 — [RFC 0/3] Portable Device Tree Connector

FromPantelis Antoniou <pantelis.antoniou@konsulko.com>
Date2016-06-03 22:40 +0200
Subject[RFC 0/3] Portable Device Tree Connector
Message-ID<rG42R-7WA-9@gated-at.bofh.it>
This patchset introduces a portable device tree based connector.
It allows definition of a connector in a portable format so that
hardware expansion boards that utilize it can use the same
DT hardware definitions unchanged for all the boards that
have the same kind of connector.

It completely abstracts away the baseboard implementation details
and allows one to describe the expansion board in it's isolated
domain without having to figure out the per-board specific
hardware configuration.

The first patchset is the implementation while the next two
define a connector for the beaglebone board.

There was a session at ELC2016 with the slides at
http://elinux.org/images/d/d0/Panto.pdf

This patchset is dependent on the previous two patchset I sent out
some time ago.

"of: dynamic: Changesets helpers & fixes"
"gpio: of: Support cascaded GPIO"

Pantelis Antoniou (3):
  of: Portable Device Tree connector
  dts: Beaglebone portable connector definitions
  dts: beaglebone: Portable connector BB_RELAY_4PORT definition

 arch/arm/boot/dts/am335x-bone-common.dtsi | 1678 +++++++++++++++++++++++++++++
 drivers/extcon/Kconfig                    |   20 +
 drivers/extcon/Makefile                   |    3 +
 drivers/extcon/extcon-dt-con-gpio.c       |  337 ++++++
 drivers/extcon/extcon-dt-con-proxy.c      |  480 +++++++++
 drivers/extcon/extcon-dt-con.c            |  491 +++++++++
 drivers/extcon/extcon-dt-con.h            |   93 ++
 7 files changed, 3102 insertions(+)
 create mode 100644 drivers/extcon/extcon-dt-con-gpio.c
 create mode 100644 drivers/extcon/extcon-dt-con-proxy.c
 create mode 100644 drivers/extcon/extcon-dt-con.c
 create mode 100644 drivers/extcon/extcon-dt-con.h

-- 
1.7.12

[toc] | [next] | [standalone]


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

FromPantelis Antoniou <pantelis.antoniou@konsulko.com>
Date2016-06-03 22:40 +0200
Subject[RFC 3/3] dts: beaglebone: Portable connector BB_RELAY_4PORT definition
Message-ID<rG42S-7WA-21@gated-at.bofh.it>
In reply to#1413456
Example of a portable connector port for the BB_RELAY_4PORT cape

Signed-off-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com>
---
 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

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web