devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Florian Vaussard <florian.vaussard@epfl.ch>
To: Benoit Cousson <b-cousson@ti.com>
Cc: Tony Lindgren <tony@atomide.com>,
	Vaibhav Hiremath <hvaibhav@ti.com>,
	Joel A Fernandes <agnel.joel@gmail.com>,
	linux-omap@vger.kernel.org, devicetree-discuss@lists.ozlabs.org,
	linux-arm-kernel@lists.infradead.org,
	Florian Vaussard <florian.vaussard@epfl.ch>
Subject: [PATCH v2 3/4] ARM: dts: AM33XX: Specific pinctrl header
Date: Mon,  3 Jun 2013 16:12:24 +0200	[thread overview]
Message-ID: <1370268745-15860-4-git-send-email-florian.vaussard@epfl.ch> (raw)
In-Reply-To: <1370268745-15860-1-git-send-email-florian.vaussard@epfl.ch>

The pinctrl IP inside the AM33XX family differs slightly from
what is found on OMAP2+. Define a specific header to take account
of the differences.

Signed-off-by: Florian Vaussard <florian.vaussard@epfl.ch>
---
 include/dt-bindings/pinctrl/am33xx.h |   37 ++++++++++++++++++++++++++++++++++
 1 files changed, 37 insertions(+), 0 deletions(-)
 create mode 100644 include/dt-bindings/pinctrl/am33xx.h

diff --git a/include/dt-bindings/pinctrl/am33xx.h b/include/dt-bindings/pinctrl/am33xx.h
new file mode 100644
index 0000000..a3fddd4
--- /dev/null
+++ b/include/dt-bindings/pinctrl/am33xx.h
@@ -0,0 +1,37 @@
+/*
+ * This header provides constants specific to AM33XX pinctrl bindings.
+ */
+
+#include <include/dt-bindings/pinctrl/omap.h>
+
+/* am33xx specific mux bit defines */
+#undef PULL_ENA
+#undef INPUT_EN
+
+#define PULL_DISABLE		(1 << 3)
+#define INPUT_EN		(1 << 5)
+#define SLEWCTRL_FAST		(1 << 6)
+
+/* update macro depending on INPUT_EN and PULL_ENA */
+#undef PIN_OUTPUT
+#undef PIN_OUTPUT_PULLUP
+#undef PIN_OUTPUT_PULLDOWN
+#undef PIN_INPUT
+#undef PIN_INPUT_PULLUP
+#undef PIN_INPUT_PULLDOWN
+
+#define PIN_OUTPUT		(PULL_DISABLE)
+#define PIN_OUTPUT_PULLUP	(PULL_UP)
+#define PIN_OUTPUT_PULLDOWN	0
+#define PIN_INPUT		(INPUT_EN | PULL_DISABLE)
+#define PIN_INPUT_PULLUP	(INPUT_EN | PULL_UP)
+#define PIN_INPUT_PULLDOWN	(INPUT_EN)
+
+/* undef non-existing modes */
+#undef PIN_OFF_NONE
+#undef PIN_OFF_OUTPUT_HIGH
+#undef PIN_OFF_OUTPUT_LOW
+#undef PIN_OFF_INPUT_PULLUP
+#undef PIN_OFF_INPUT_PULLDOWN
+#undef PIN_OFF_WAKEUPENABLE
+
-- 
1.7.5.4


  parent reply	other threads:[~2013-06-03 14:12 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-03 14:12 [PATCH v2 0/4] ARM: dts: AM3XXX: Use preprocessor for device trees Florian Vaussard
     [not found] ` <1370268745-15860-1-git-send-email-florian.vaussard-p8DiymsW2f8@public.gmane.org>
2013-06-03 14:12   ` [PATCH v2 1/4] ARM: dts: AM3XXX: Use #include for all " Florian Vaussard
2013-06-03 14:12 ` [PATCH v2 2/4] ARM: dts: AM33XX: Use existing constants for GPIOs Florian Vaussard
2013-06-03 14:12 ` Florian Vaussard [this message]
2013-06-03 14:12 ` [PATCH v2 4/4] ARM: dts: AM33XX: Use pinctrl constants Florian Vaussard
2013-06-05 12:49 ` [PATCH v2 0/4] ARM: dts: AM3XXX: Use preprocessor for device trees Benoit Cousson
     [not found]   ` <51AF33BC.4020708-l0cyMroinI0@public.gmane.org>
2013-06-06  5:28     ` Mohammed, Afzal
     [not found]       ` <C8443D0743D26F4388EA172BF4E2A7A93EB16EED-yXqyApvAXouIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
2013-06-06  7:22         ` Benoit Cousson
     [not found]           ` <51B038B2.4020007-l0cyMroinI0@public.gmane.org>
2013-06-06  7:34             ` Florian Vaussard

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=1370268745-15860-4-git-send-email-florian.vaussard@epfl.ch \
    --to=florian.vaussard@epfl.ch \
    --cc=agnel.joel@gmail.com \
    --cc=b-cousson@ti.com \
    --cc=devicetree-discuss@lists.ozlabs.org \
    --cc=hvaibhav@ti.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=tony@atomide.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).