devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Naveen Krishna Chatradhi <ch.naveen@samsung.com>
To: linux-samsung-soc@vger.kernel.org, devicetree@vger.kernel.org
Cc: linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org,
	dianders@chromium.org, gregkh@linuxfoundation.org,
	naveenkrishna.ch@gmail.com, cpgs@samsung.com
Subject: [PATCH 3/3] ARM: DTS: Add common dts file for Peach PIT and PI along with ADC nodes
Date: Thu, 26 Jun 2014 17:49:08 +0530	[thread overview]
Message-ID: <1403785148-20792-4-git-send-email-ch.naveen@samsung.com> (raw)
In-Reply-To: <1403785148-20792-1-git-send-email-ch.naveen@samsung.com>

DTS files exynos5420-peach-pit.dts and exynos5800-peach-pi.dts
have lots of device tree nodes in common.

This patch creates a cros-exynos-peach.dts file, which can carry the
device tree nodes common across exynos5420-peach-pit.dts and
exynos5800-peach-pi.dts. Starting with ADC based Thermistor nodes.

Also, enables ADC based thermistors for peach_pi and peach_pit.

Signed-off-by: Naveen Krishna Chatradhi <ch.naveen@samsung.com>
---
This patchset needs
"[PATCH v4 00/14] Add Maxim 77802 PMIC support" by "Javier Martinez Canillas"
Posted  https://lkml.org/lkml/2014/6/25/668

Intention is to slowly move the common DT nodes across exynos5420-peach-pit.dts
and exynos5800-peach-pi.dts into cros-exynos-peach.dts

I'm unsure of the naming conventions for dts files
   Named it "cros-exynos-peach.dts" as below.
   used for "cros" + based on "exynos" + boards named "peach" in common.

cat sysfs entries exported by hwmon for 4 thermistors
and verified the values on peach pit.

 arch/arm/boot/dts/cros-exynos-peach.dtsi   |   41 ++++++++++++++++++++++++++++
 arch/arm/boot/dts/exynos5420-peach-pit.dts |    6 ++++
 arch/arm/boot/dts/exynos5800-peach-pi.dts  |    6 ++++
 3 files changed, 53 insertions(+)
 create mode 100644 arch/arm/boot/dts/cros-exynos-peach.dtsi

diff --git a/arch/arm/boot/dts/cros-exynos-peach.dtsi b/arch/arm/boot/dts/cros-exynos-peach.dtsi
new file mode 100644
index 0000000..86135bd
--- /dev/null
+++ b/arch/arm/boot/dts/cros-exynos-peach.dtsi
@@ -0,0 +1,41 @@
+/*
+ * Common device tree include for Exynos5420 based Peach PIT and
+ * Exynos5800 based Peach PI.
+ *
+ * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+*/
+
+&adc {
+	ncp15wb473@3 {
+		compatible = "murata,ncp15wb473";
+		pullup-uv = <1800000>;
+		pullup-ohm = <47000>;
+		pulldown-ohm = <0>;
+		io-channels = <&adc 3>;
+	};
+	ncp15wb473@4 {
+		compatible = "murata,ncp15wb473";
+		pullup-uv = <1800000>;
+		pullup-ohm = <47000>;
+		pulldown-ohm = <0>;
+		io-channels = <&adc 4>;
+	};
+	ncp15wb473@5 {
+		compatible = "murata,ncp15wb473";
+		pullup-uv = <1800000>;
+		pullup-ohm = <47000>;
+		pulldown-ohm = <0>;
+		io-channels = <&adc 5>;
+	};
+	ncp15wb473@6 {
+		compatible = "murata,ncp15wb473";
+		pullup-uv = <1800000>;
+		pullup-ohm = <47000>;
+		pulldown-ohm = <0>;
+		io-channels = <&adc 6>;
+	};
+};
diff --git a/arch/arm/boot/dts/exynos5420-peach-pit.dts b/arch/arm/boot/dts/exynos5420-peach-pit.dts
index d124394..682b9c2 100644
--- a/arch/arm/boot/dts/exynos5420-peach-pit.dts
+++ b/arch/arm/boot/dts/exynos5420-peach-pit.dts
@@ -12,6 +12,7 @@
 #include <dt-bindings/input/input.h>
 #include <dt-bindings/gpio/gpio.h>
 #include "exynos5420.dtsi"
+#include "cros-exynos-peach.dtsi"
 
 / {
 	model = "Google Peach Pit Rev 6+";
@@ -101,6 +102,11 @@
 	};
 };
 
+&adc {
+	status = "okay";
+	vdd-supply = <&ldo9_reg>;
+};
+
 &dp {
 	status = "okay";
 	pinctrl-names = "default";
diff --git a/arch/arm/boot/dts/exynos5800-peach-pi.dts b/arch/arm/boot/dts/exynos5800-peach-pi.dts
index c36c9ce..7552173 100644
--- a/arch/arm/boot/dts/exynos5800-peach-pi.dts
+++ b/arch/arm/boot/dts/exynos5800-peach-pi.dts
@@ -12,6 +12,7 @@
 #include <dt-bindings/input/input.h>
 #include <dt-bindings/gpio/gpio.h>
 #include "exynos5800.dtsi"
+#include "cros-exynos-peach.dtsi"
 
 / {
 	model = "Google Peach Pi Rev 10+";
@@ -99,6 +100,11 @@
 	};
 };
 
+&adc {
+	status = "okay";
+	vdd-supply = <&ldo9_reg>;
+};
+
 &dp {
 	status = "okay";
 	pinctrl-names = "default";
-- 
1.7.9.5

  parent reply	other threads:[~2014-06-26 12:19 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-26 12:19 [PATCH 0/3] ARM: DTS: create common dtsi for Peach pit and pi boards Naveen Krishna Chatradhi
2014-06-26 12:19 ` [PATCH 1/3] ARM: DTS: use new compatible string for thermistors in trats2 Naveen Krishna Chatradhi
     [not found] ` <1403785148-20792-1-git-send-email-ch.naveen-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2014-06-26 12:19   ` [PATCH 2/3] ARM: DTS: Add NTC thermistor nodes to Exynos5250 based Snow Naveen Krishna Chatradhi
     [not found]     ` <1403785148-20792-3-git-send-email-ch.naveen-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2014-06-26 15:46       ` Doug Anderson
     [not found]         ` <CAD=FV=W=e-5LJRacxA-sSUUn8cBB5oCHJkwz=Py7iU2fdERVRA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-06-26 16:53           ` Naveen Krishna Ch
2014-06-26 12:19 ` Naveen Krishna Chatradhi [this message]
2014-06-26 15:21 ` [PATCH 0/3] ARM: DTS: create common dtsi for Peach pit and pi boards Javier Martinez Canillas
     [not found]   ` <CABxcv=nTfkRkpz_zZuxYHznjDuNgpiKO+FD4MnHi2C_2e32eqA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-06-26 16:38     ` Naveen Krishna Ch
2014-06-26 23:53       ` Doug Anderson

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=1403785148-20792-4-git-send-email-ch.naveen@samsung.com \
    --to=ch.naveen@samsung.com \
    --cc=cpgs@samsung.com \
    --cc=devicetree@vger.kernel.org \
    --cc=dianders@chromium.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=naveenkrishna.ch@gmail.com \
    /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;
as well as URLs for NNTP newsgroup(s).