linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] pinctrl: dra: dt-bindings: Add virtual mode configuration option
@ 2015-06-22 15:22 Nishanth Menon
  2015-07-14 11:10 ` Tony Lindgren
  0 siblings, 1 reply; 2+ messages in thread
From: Nishanth Menon @ 2015-06-22 15:22 UTC (permalink / raw)
  To: Tony Lindgren
  Cc: linux-kernel, linux-arm-kernel, linux-omap, devicetree, Nishanth Menon

In addition to the regular mux configuration such as mux mode 1,
2 etc, certain pins of DRA7 require to have "virtual mode" also
programmed. This allows for predefined delay characteristics to
be used by the SoC to meet timing characterstics needed for the
interface.

Provide easy to use macro to do the same.

It is important to note that the official TI guidelines recommend
to do as minimal pin reconfiguration beyond the bootloader given
the design of the hardware involved which can result in substantial
glitches which may impair functionality of certain peripherals.

Signed-off-by: Nishanth Menon <nm@ti.com>
---

Baseline: v4.1

 include/dt-bindings/pinctrl/dra.h |   20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)

diff --git a/include/dt-bindings/pinctrl/dra.h b/include/dt-bindings/pinctrl/dra.h
index 7448edff4723..4379e29f0460 100644
--- a/include/dt-bindings/pinctrl/dra.h
+++ b/include/dt-bindings/pinctrl/dra.h
@@ -30,6 +30,26 @@
 #define MUX_MODE14	0xe
 #define MUX_MODE15	0xf
 
+/* Certain pins need virtual mode, but note: they may glitch */
+#define MUX_VIRTUAL_MODE0	(MODE_SELECT | (0x0 << 4))
+#define MUX_VIRTUAL_MODE1	(MODE_SELECT | (0x1 << 4))
+#define MUX_VIRTUAL_MODE2	(MODE_SELECT | (0x2 << 4))
+#define MUX_VIRTUAL_MODE3	(MODE_SELECT | (0x3 << 4))
+#define MUX_VIRTUAL_MODE4	(MODE_SELECT | (0x4 << 4))
+#define MUX_VIRTUAL_MODE5	(MODE_SELECT | (0x5 << 4))
+#define MUX_VIRTUAL_MODE6	(MODE_SELECT | (0x6 << 4))
+#define MUX_VIRTUAL_MODE7	(MODE_SELECT | (0x7 << 4))
+#define MUX_VIRTUAL_MODE8	(MODE_SELECT | (0x8 << 4))
+#define MUX_VIRTUAL_MODE9	(MODE_SELECT | (0x9 << 4))
+#define MUX_VIRTUAL_MODE10	(MODE_SELECT | (0xa << 4))
+#define MUX_VIRTUAL_MODE11	(MODE_SELECT | (0xb << 4))
+#define MUX_VIRTUAL_MODE12	(MODE_SELECT | (0xc << 4))
+#define MUX_VIRTUAL_MODE13	(MODE_SELECT | (0xd << 4))
+#define MUX_VIRTUAL_MODE14	(MODE_SELECT | (0xe << 4))
+#define MUX_VIRTUAL_MODE15	(MODE_SELECT | (0xf << 4))
+
+#define MODE_SELECT		(1 << 8)
+
 #define PULL_ENA		(0 << 16)
 #define PULL_DIS		(1 << 16)
 #define PULL_UP			(1 << 17)
-- 
1.7.9.5

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
Please read the FAQ at  http://www.tux.org/lkml/

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] pinctrl: dra: dt-bindings: Add virtual mode configuration option
  2015-06-22 15:22 [PATCH] pinctrl: dra: dt-bindings: Add virtual mode configuration option Nishanth Menon
@ 2015-07-14 11:10 ` Tony Lindgren
  0 siblings, 0 replies; 2+ messages in thread
From: Tony Lindgren @ 2015-07-14 11:10 UTC (permalink / raw)
  To: Nishanth Menon; +Cc: linux-kernel, linux-arm-kernel, linux-omap, devicetree

* Nishanth Menon <nm@ti.com> [150622 08:24]:
> In addition to the regular mux configuration such as mux mode 1,
> 2 etc, certain pins of DRA7 require to have "virtual mode" also
> programmed. This allows for predefined delay characteristics to
> be used by the SoC to meet timing characterstics needed for the
> interface.
> 
> Provide easy to use macro to do the same.
> 
> It is important to note that the official TI guidelines recommend
> to do as minimal pin reconfiguration beyond the bootloader given
> the design of the hardware involved which can result in substantial
> glitches which may impair functionality of certain peripherals.

Applying into omap-for-v4.3/dt thanks.

Tony

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-07-14 11:10 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-06-22 15:22 [PATCH] pinctrl: dra: dt-bindings: Add virtual mode configuration option Nishanth Menon
2015-07-14 11:10 ` Tony Lindgren

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).