diff options
author | Tony Lindgren <tony@atomide.com> | 2010-12-22 21:42:35 -0500 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2010-12-22 21:42:35 -0500 |
commit | 8d9af88f55be89fa4c897ded3204ef12c947731e (patch) | |
tree | c9ce0643af4a2c35f456df470e27f28982abf68e /arch/arm/mach-omap2/mux.h | |
parent | 9796b323b5a1940f9ec62c3a6cf7e442bf540d53 (diff) |
omap2+: Allow hwmod state changes to mux pads based on the state changes
Allow hwmod state changes to mux pads based on the state changes.
By default, only enable and disable the pads. In some rare cases
dynamic remuxing for the idles states is needed, this can be done
by passing the enable, idle, and off pads from board-*.c file along
with OMAP_DEVICE_PAD_REMUX flag.
Thanks to Paul Walmsley <paul@booyaka.com> for the comments on the
hwmod related changes.
Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm/mach-omap2/mux.h')
-rw-r--r-- | arch/arm/mach-omap2/mux.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/mux.h b/arch/arm/mach-omap2/mux.h index 9c48b9d3ec29..c9ec50de99c9 100644 --- a/arch/arm/mach-omap2/mux.h +++ b/arch/arm/mach-omap2/mux.h | |||
@@ -171,6 +171,8 @@ struct omap_device_pad { | |||
171 | struct omap_mux *mux; | 171 | struct omap_mux *mux; |
172 | }; | 172 | }; |
173 | 173 | ||
174 | struct omap_hwmod_mux_info; | ||
175 | |||
174 | #if defined(CONFIG_OMAP_MUX) | 176 | #if defined(CONFIG_OMAP_MUX) |
175 | 177 | ||
176 | /** | 178 | /** |
@@ -195,6 +197,15 @@ int omap_mux_init_signal(const char *muxname, int val); | |||
195 | extern struct omap_hwmod_mux_info * | 197 | extern struct omap_hwmod_mux_info * |
196 | omap_hwmod_mux_init(struct omap_device_pad *bpads, int nr_pads); | 198 | omap_hwmod_mux_init(struct omap_device_pad *bpads, int nr_pads); |
197 | 199 | ||
200 | /** | ||
201 | * omap_hwmod_mux - omap hwmod specific pin muxing | ||
202 | * @hmux: Pads for a hwmod | ||
203 | * @state: Desired _HWMOD_STATE | ||
204 | * | ||
205 | * Called only from omap_hwmod.c, do not use. | ||
206 | */ | ||
207 | void omap_hwmod_mux(struct omap_hwmod_mux_info *hmux, u8 state); | ||
208 | |||
198 | #else | 209 | #else |
199 | 210 | ||
200 | static inline int omap_mux_init_gpio(int gpio, int val) | 211 | static inline int omap_mux_init_gpio(int gpio, int val) |
@@ -212,6 +223,10 @@ omap_hwmod_mux_init(struct omap_device_pad *bpads, int nr_pads) | |||
212 | return NULL; | 223 | return NULL; |
213 | } | 224 | } |
214 | 225 | ||
226 | static inline void omap_hwmod_mux(struct omap_hwmod_mux_info *hmux, u8 state) | ||
227 | { | ||
228 | } | ||
229 | |||
215 | static struct omap_board_mux *board_mux __initdata __maybe_unused; | 230 | static struct omap_board_mux *board_mux __initdata __maybe_unused; |
216 | 231 | ||
217 | #endif | 232 | #endif |