Patchwork [U-Boot,02/11] tegra20: add entry point and helper for tablebased pinmux

login
register
mail settings
Submitter Lucas Stach
Date Jan. 24, 2013, 4:48 p.m.
Message ID <1359046100-19385-3-git-send-email-dev@lynxeye.de>
Download mbox | patch
Permalink /patch/215446/
State Deferred
Delegated to: Tom Warren
Headers show

Comments

Lucas Stach - Jan. 24, 2013, 4:48 p.m.
Signed-off-by: Lucas Stach <dev@lynxeye.de>
---
 arch/arm/include/asm/arch-tegra20/pinmux.h | 12 ++++++++++++
 1 file changed, 12 insertions(+)

Patch

diff --git a/arch/arm/include/asm/arch-tegra20/pinmux.h b/arch/arm/include/asm/arch-tegra20/pinmux.h
index a9b4eda..a167e48 100644
--- a/arch/arm/include/asm/arch-tegra20/pinmux.h
+++ b/arch/arm/include/asm/arch-tegra20/pinmux.h
@@ -350,4 +350,16 @@  void pinmux_set_tristate(enum pmux_pingrp pin, int enable);
  */
 void pinmux_config_table(const struct pingroup_config *config, int len);
 
+/* Set a group of pins from a table */
+void pinmux_init(void);
+
+/* helper to fill pinmux table */
+#define PINMUX_ENTRY(_pingroup, _mux, _pull, _tri)	\
+	{						\
+		.pingroup	= PINGRP_##_pingroup,	\
+		.func		= PMUX_FUNC_##_mux,	\
+		.pull		= PMUX_PULL_##_pull,	\
+		.tristate	= PMUX_TRI_##_tri,	\
+	}
+
 #endif	/* PINMUX_H */