Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: shc_work@mail.ru (Alexander Shiyan)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: dts: imx27-phytec-phycore-*: Add diagnostic PMIC LEDs
Date: Sat, 15 Feb 2014 15:35:18 +0400	[thread overview]
Message-ID: <1392464118-3353-1-git-send-email-shc_work@mail.ru> (raw)

PCM-038 module have three triple LEDs connected to PMIC which
can be used for diagnostic purposes. This patch adds support
for these LEDs for PCM-038 SOM and adds basic LED-triggers for
these LEDs for PCM-970 RDK, the remaining LEDs are available
for use from userspace.

Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
---
 arch/arm/boot/dts/imx27-phytec-phycore-rdk.dts  | 50 +++++++++++++++++++++++++
 arch/arm/boot/dts/imx27-phytec-phycore-som.dtsi |  6 +++
 2 files changed, 56 insertions(+)

diff --git a/arch/arm/boot/dts/imx27-phytec-phycore-rdk.dts b/arch/arm/boot/dts/imx27-phytec-phycore-rdk.dts
index 9f8ad51..9a07543 100644
--- a/arch/arm/boot/dts/imx27-phytec-phycore-rdk.dts
+++ b/arch/arm/boot/dts/imx27-phytec-phycore-rdk.dts
@@ -96,6 +96,56 @@
 	status = "okay";
 };
 
+&pmicleds {
+	ledr1: led at 3 {
+		reg = <3>;
+		label = "system:red1:user";
+	};
+
+	ledg1: led at 4 {
+		reg = <4>;
+		label = "system:green1:user";
+	};
+
+	ledb1: led at 5 {
+		reg = <5>;
+		label = "system:blue1:user";
+	};
+
+	ledr2: led at 6 {
+		reg = <6>;
+		label = "system:red2:user";
+	};
+
+	ledg2: led at 7 {
+		reg = <7>;
+		label = "system:green2:user";
+	};
+
+	ledb2: led at 8 {
+		reg = <8>;
+		label = "system:blue2:user";
+	};
+
+	ledr3: led at 9 {
+		reg = <9>;
+		label = "system:red3:nand";
+		linux,default-trigger = "nand-disk";
+	};
+
+	ledg3: led at 10 {
+		reg = <10>;
+		label = "system:green3:live";
+		linux,default-trigger = "heartbeat";
+	};
+
+	ledb3: led at 11 {
+		reg = <11>;
+		label = "system:blue3:cpu";
+		linux,default-trigger = "cpu0";
+	};
+};
+
 &sdhci2 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_sdhc2>;
diff --git a/arch/arm/boot/dts/imx27-phytec-phycore-som.dtsi b/arch/arm/boot/dts/imx27-phytec-phycore-som.dtsi
index 230cfaf..258eafa 100644
--- a/arch/arm/boot/dts/imx27-phytec-phycore-som.dtsi
+++ b/arch/arm/boot/dts/imx27-phytec-phycore-som.dtsi
@@ -69,6 +69,12 @@
 		fsl,mc13xxx-uses-adc;
 		fsl,mc13xxx-uses-rtc;
 
+		pmicleds: leds {
+			#address-cells = <1>;
+			#size-cells = <0>;
+			led-control = <0x001 0x000 0x000 0x000 0x000 0x000>;
+		};
+
 		regulators {
 			/* SW1A and SW1B joined operation */
 			sw1_reg: sw1a {
-- 
1.8.3.2

             reply	other threads:[~2014-02-15 11:35 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-15 11:35 Alexander Shiyan [this message]
2014-02-17  2:55 ` [PATCH] ARM: dts: imx27-phytec-phycore-*: Add diagnostic PMIC LEDs Shawn Guo
2014-02-17  4:35   ` Alexander Shiyan
2014-02-17  5:23     ` Shawn Guo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1392464118-3353-1-git-send-email-shc_work@mail.ru \
    --to=shc_work@mail.ru \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox