aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap2/serial.c
diff options
context:
space:
mode:
authorKevin Hilman <khilman@deeprootsystems.com>2010-09-27 10:49:53 -0400
committerKevin Hilman <khilman@deeprootsystems.com>2010-09-29 15:42:58 -0400
commit3244fcd227526a2f21018a280c7af0a9219c6ff4 (patch)
tree5c99bcb6e97df85ef5d597565e40b028711c6b47 /arch/arm/mach-omap2/serial.c
parentc04ede382a64020f19e9aa23a85493a09af945d3 (diff)
OMAP: UART: don't do automatic bus-level suspend/resume
Since the omap_device for UART is currently managed inside the idle path itself, don't let the bus-level code suspend/resume the UART. To prevent this, pm_runtime_get() is used when preparing for suspend and pm_runtime_put() is used when finished with suspend. Signed-off-by: Govindraj.R <govindraj.raja@ti.com> Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Diffstat (limited to 'arch/arm/mach-omap2/serial.c')
-rw-r--r--arch/arm/mach-omap2/serial.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/arch/arm/mach-omap2/serial.c b/arch/arm/mach-omap2/serial.c
index 6ffbc924c4d4..ff83e91e6109 100644
--- a/arch/arm/mach-omap2/serial.c
+++ b/arch/arm/mach-omap2/serial.c
@@ -26,6 +26,7 @@
26#include <linux/platform_device.h> 26#include <linux/platform_device.h>
27#include <linux/slab.h> 27#include <linux/slab.h>
28#include <linux/serial_8250.h> 28#include <linux/serial_8250.h>
29#include <linux/pm_runtime.h>
29 30
30#ifdef CONFIG_SERIAL_OMAP 31#ifdef CONFIG_SERIAL_OMAP
31#include <plat/omap-serial.h> 32#include <plat/omap-serial.h>
@@ -530,14 +531,17 @@ void omap_uart_enable_irqs(int enable)
530 struct omap_uart_state *uart; 531 struct omap_uart_state *uart;
531 532
532 list_for_each_entry(uart, &uart_list, node) { 533 list_for_each_entry(uart, &uart_list, node) {
533 if (enable) 534 if (enable) {
535 pm_runtime_put_sync(&uart->pdev->dev);
534 ret = request_threaded_irq(uart->irq, NULL, 536 ret = request_threaded_irq(uart->irq, NULL,
535 omap_uart_interrupt, 537 omap_uart_interrupt,
536 IRQF_SHARED, 538 IRQF_SHARED,
537 "serial idle", 539 "serial idle",
538 (void *)uart); 540 (void *)uart);
539 else 541 } else {
542 pm_runtime_get_noresume(&uart->pdev->dev);
540 free_irq(uart->irq, (void *)uart); 543 free_irq(uart->irq, (void *)uart);
544 }
541 } 545 }
542} 546}
543 547