Re: [PATCH 3/3] serial: 8250: omap: restore registers on shutdown

2015-08-06 Thread Charles Manning
On Fri, Aug 7, 2015 at 6:22 AM, Peter Hurley pe...@hurleysoftware.com wrote: I agree; this is what we should do first because someone might want it for backports. Got an idea how far this can be ported back? I'm being hampered by severe performance issues on a beagleboneblack-like device

Re: [PATCH 3/3] serial: 8250: omap: restore registers on shutdown

2015-08-06 Thread Peter Hurley
Hi Sebastian, On 08/04/2015 07:58 AM, Sebastian Andrzej Siewior wrote: On 08/03/2015 09:32 PM, Peter Hurley wrote: You mean a function in 8250-dma API which does what I did just here with the wait_event() and the wake_up in the callback? That way I could move the termios_wait into the dma

Re: [PATCH 3/3] serial: 8250: omap: restore registers on shutdown

2015-08-06 Thread Sebastian Andrzej Siewior
On 08/06/2015 02:27 PM, Peter Hurley wrote: Hi Sebastian, Hi Peter, On 08/04/2015 07:58 AM, Sebastian Andrzej Siewior wrote: On 08/03/2015 09:32 PM, Peter Hurley wrote: You mean a function in 8250-dma API which does what I did just here with the wait_event() and the wake_up in the

Re: [PATCH 3/3] serial: 8250: omap: restore registers on shutdown

2015-08-06 Thread Peter Hurley
On 08/06/2015 09:59 AM, Sebastian Andrzej Siewior wrote: On 08/06/2015 02:31 PM, Sebastian Andrzej Siewior wrote: Hi Peter, I'll look at/test this this weekend, ok? Sure. I'm currently re-spinning the patches so have everything in proper pieces. While at it I will take a look at x_char.

Re: [PATCH 3/3] serial: 8250: omap: restore registers on shutdown

2015-08-06 Thread Sebastian Andrzej Siewior
On 08/06/2015 02:31 PM, Sebastian Andrzej Siewior wrote: Hi Peter, I'll look at/test this this weekend, ok? Sure. I'm currently re-spinning the patches so have everything in proper pieces. While at it I will take a look at x_char. So now that I actually look at it. If I read this right, we

Re: [PATCH 3/3] serial: 8250: omap: restore registers on shutdown

2015-08-04 Thread Sebastian Andrzej Siewior
On 08/03/2015 09:32 PM, Peter Hurley wrote: You mean a function in 8250-dma API which does what I did just here with the wait_event() and the wake_up in the callback? That way I could move the termios_wait into the dma struct instead of keeping in the omap specific part. I am also not sure if

Re: [PATCH 3/3] serial: 8250: omap: restore registers on shutdown

2015-08-03 Thread Sebastian Andrzej Siewior
* Peter Hurley | 2015-07-30 20:51:10 [-0400]: Hi John, Hi Peter, I was never really a fan of the deferred set_termios(); I think it's more appropriate to wait for tx dma to complete in omap_8250_set_termios(). So you want something like this? This was only compile + boot tested (without

Re: [PATCH 3/3] serial: 8250: omap: restore registers on shutdown

2015-08-03 Thread Sebastian Andrzej Siewior
On 08/03/2015 06:34 PM, Peter Hurley wrote: Hi Sebastian, Hi Peter, struct old_serial_port { diff --git a/drivers/tty/serial/8250/8250_omap.c b/drivers/tty/serial/8250/8250_omap.c index d9a37191a1ae..12249125a218 100644 --- a/drivers/tty/serial/8250/8250_omap.c +++

Re: [PATCH 3/3] serial: 8250: omap: restore registers on shutdown

2015-08-03 Thread Peter Hurley
[ +cc Heikki ] Hi Sebastian, On 08/03/2015 12:09 PM, Sebastian Andrzej Siewior wrote: * Peter Hurley | 2015-07-30 20:51:10 [-0400]: Hi John, Hi Peter, I was never really a fan of the deferred set_termios(); I think it's more appropriate to wait for tx dma to complete in

Re: [PATCH 3/3] serial: 8250: omap: restore registers on shutdown

2015-08-03 Thread Peter Hurley
On 08/03/2015 12:54 PM, Sebastian Andrzej Siewior wrote: On 08/03/2015 06:34 PM, Peter Hurley wrote: Hi Sebastian, Hi Peter, struct old_serial_port { diff --git a/drivers/tty/serial/8250/8250_omap.c b/drivers/tty/serial/8250/8250_omap.c index d9a37191a1ae..12249125a218 100644 ---

[PATCH 3/3] serial: 8250: omap: restore registers on shutdown

2015-07-30 Thread John Ogness
If DMA is active during a shutdown, a delayed restore of the registers may be pending. The restore must be performed after the DMA is stopped, otherwise the delayed restore remains pending and will fire upon the first DMA TX complete of a totally different serial session. Signed-off-by: John

Re: [PATCH 3/3] serial: 8250: omap: restore registers on shutdown

2015-07-30 Thread Peter Hurley
Hi John, On 07/30/2015 06:54 PM, John Ogness wrote: If DMA is active during a shutdown, a delayed restore of the registers may be pending. The restore must be performed after the DMA is stopped, otherwise the delayed restore remains pending and will fire upon the first DMA TX complete of a