linux-serial.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* serial/imx.c : wrong baudrate at resume if console is on UART
@ 2010-05-27 21:02 Eric Bénard
  2010-05-31  7:33 ` Eric Bénard
  0 siblings, 1 reply; 2+ messages in thread
From: Eric Bénard @ 2010-05-27 21:02 UTC (permalink / raw)
  To: linux-serial

Hi,

while testing suspend/resume on i.MX27, I meet a problem on resume : if 
the console is on the UART the baudrate it not restored properly (I get 
random bitrate between 50 to 2Mbps). Here is a patch to add pm to the 
uart_ops (but the problem occurs also without this patch) :
http://lists.infradead.org/pipermail/linux-arm-kernel/2010-May/016495.html

What is strange is that giving wrong structures (platform_device instead 
of device) in suspend/resume functions as in following patch "fix" the 
problem :
http://lists.infradead.org/pipermail/linux-arm-kernel/2010-May/015985.html

Do you have any idea of what could be wrong there ?

Many thanks,
Eric

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

* Re: serial/imx.c : wrong baudrate at resume if console is on UART
  2010-05-27 21:02 serial/imx.c : wrong baudrate at resume if console is on UART Eric Bénard
@ 2010-05-31  7:33 ` Eric Bénard
  0 siblings, 0 replies; 2+ messages in thread
From: Eric Bénard @ 2010-05-31  7:33 UTC (permalink / raw)
  To: linux-serial

Hi,

Le 27/05/2010 23:02, Eric Bénard a écrit :
> while testing suspend/resume on i.MX27, I meet a problem on resume : if
> the console is on the UART the baudrate it not restored properly (I get
> random bitrate between 50 to 2Mbps). Here is a patch to add pm to the
> uart_ops (but the problem occurs also without this patch) :
> http://lists.infradead.org/pipermail/linux-arm-kernel/2010-May/016495.html
>
I've noticed that commenting out the following line in serial_core.c 
"fix" the problem :
diff --git a/drivers/serial/serial_core.c b/drivers/serial/serial_core.c
index 7f28307..c63476e 100644
--- a/drivers/serial/serial_core.c
+++ b/drivers/serial/serial_core.c
@@ -2092,7 +2092,7 @@ int uart_resume_port(struct uart_driver *drv, 
struct uart_
          */
         if (uart_console(uport)) {
                 uart_change_pm(state, 0);
-               uport->ops->set_termios(uport, &termios, NULL);
+//             uport->ops->set_termios(uport, &termios, NULL);
                 console_start(uport->cons);
         }

Do you have a hint of why the baudrate is not properly restored for the 
console or where I should dig to fix this in serial/imx.c ?

Thanks
Eric
--
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

end of thread, other threads:[~2010-05-31  7:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-27 21:02 serial/imx.c : wrong baudrate at resume if console is on UART Eric Bénard
2010-05-31  7:33 ` Eric Bénard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).