diff options
-rw-r--r-- | arch/arm/mach-omap2/serial.c | 23 |
1 files changed, 21 insertions, 2 deletions
diff --git a/arch/arm/mach-omap2/serial.c b/arch/arm/mach-omap2/serial.c index ff83e91e6109..72b5c9896390 100644 --- a/arch/arm/mach-omap2/serial.c +++ b/arch/arm/mach-omap2/serial.c | |||
@@ -105,10 +105,29 @@ struct omap_uart_state { | |||
105 | static LIST_HEAD(uart_list); | 105 | static LIST_HEAD(uart_list); |
106 | static u8 num_uarts; | 106 | static u8 num_uarts; |
107 | 107 | ||
108 | /* | ||
109 | * Since these idle/enable hooks are used in the idle path itself | ||
110 | * which has interrupts disabled, use the non-locking versions of | ||
111 | * the hwmod enable/disable functions. | ||
112 | */ | ||
113 | static int uart_idle_hwmod(struct omap_device *od) | ||
114 | { | ||
115 | _omap_hwmod_idle(od->hwmods[0]); | ||
116 | |||
117 | return 0; | ||
118 | } | ||
119 | |||
120 | static int uart_enable_hwmod(struct omap_device *od) | ||
121 | { | ||
122 | _omap_hwmod_enable(od->hwmods[0]); | ||
123 | |||
124 | return 0; | ||
125 | } | ||
126 | |||
108 | static struct omap_device_pm_latency omap_uart_latency[] = { | 127 | static struct omap_device_pm_latency omap_uart_latency[] = { |
109 | { | 128 | { |
110 | .deactivate_func = omap_device_idle_hwmods, | 129 | .deactivate_func = uart_idle_hwmod, |
111 | .activate_func = omap_device_enable_hwmods, | 130 | .activate_func = uart_enable_hwmod, |
112 | .flags = OMAP_DEVICE_LATENCY_AUTO_ADJUST, | 131 | .flags = OMAP_DEVICE_LATENCY_AUTO_ADJUST, |
113 | }, | 132 | }, |
114 | }; | 133 | }; |