public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Serial: BUGFIX: uart_resume_port has an omitted condition.
@ 2010-10-13  5:58 MyungJoo Ham
  2010-10-13  6:26 ` Greg KH
  0 siblings, 1 reply; 7+ messages in thread
From: MyungJoo Ham @ 2010-10-13  5:58 UTC (permalink / raw)
  To: linux-kernel
  Cc: myungjoo.ham, kyungmin.park, Greg Kroah-Hartman, Alan Cox,
	Arnd Bergmann, Andr Goddard Rosa, Stanislav Brabec

When console_suspend_enabled == 0, console_stop() was not called at
suspend; thus, it does not need to call console_start() when resume.
Besides, calling console_start() without calling console_stop() before
had been incurring kernel hang with console_suspend_enabled == 0 in a
machine with drivers/serial/samsung.c and s5pc210.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
 drivers/serial/serial_core.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/serial/serial_core.c b/drivers/serial/serial_core.c
index cd85112..ff21200 100644
--- a/drivers/serial/serial_core.c
+++ b/drivers/serial/serial_core.c
@@ -2065,7 +2065,7 @@ int uart_resume_port(struct uart_driver *drv, struct uart_port *uport)
 	/*
 	 * Re-enable the console device after suspending.
 	 */
-	if (uart_console(uport)) {
+	if (console_suspend_enabled && uart_console(uport)) {
 		uart_change_pm(state, 0);
 		uport->ops->set_termios(uport, &termios, NULL);
 		console_start(uport->cons);
-- 
1.6.3.3


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

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

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-13  5:58 [PATCH] Serial: BUGFIX: uart_resume_port has an omitted condition MyungJoo Ham
2010-10-13  6:26 ` Greg KH
2010-10-13  6:38   ` MyungJoo Ham
2010-10-13 11:26     ` Stanislav Brabec
2010-10-14 18:45       ` Greg KH
2010-10-14 19:45         ` Stanislav Brabec
2010-10-14 20:05           ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox