* [PATCH v2] serial: omap: fix the reciever line error case
@ 2012-09-21 14:37 ` Shubhrajyoti D
0 siblings, 0 replies; 6+ messages in thread
From: Shubhrajyoti D @ 2012-09-21 14:37 UTC (permalink / raw)
To: linux-serial; +Cc: linux-omap, linux-arm-kernel, Shubhrajyoti D
This patch does the following
- In case of errors if there least one data character in the RX FIFO
read it otherwise it may stall the receiver.
This is recommended in the interrupt reset method in the table 23-246 of
the omap4 TRM.
Signed-off-by: Shubhrajyoti D <shubhrajyoti@ti.com>
---
- Tested on omap4sdp.
- pm tested hitting off in idle and suspend.
- v2 changes update the changelogs.
- Also remove the dummy check as FE , PE , BI and OE are the only
receiver errors.
drivers/tty/serial/omap-serial.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/drivers/tty/serial/omap-serial.c b/drivers/tty/serial/omap-serial.c
index a0d4460..4fea16b 100644
--- a/drivers/tty/serial/omap-serial.c
+++ b/drivers/tty/serial/omap-serial.c
@@ -334,6 +334,10 @@ static unsigned int check_modem_status(struct uart_omap_port *up)
static void serial_omap_rlsi(struct uart_omap_port *up, unsigned int lsr)
{
unsigned int flag;
+ unsigned char ch = 0;
+
+ if (likely(lsr & UART_LSR_DR))
+ ch = serial_in(up, UART_RX);
up->port.icount.rx++;
flag = TTY_NORMAL;
--
1.7.5.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH v2] serial: omap: fix the reciever line error case
@ 2012-09-21 14:37 ` Shubhrajyoti D
0 siblings, 0 replies; 6+ messages in thread
From: Shubhrajyoti D @ 2012-09-21 14:37 UTC (permalink / raw)
To: linux-arm-kernel
This patch does the following
- In case of errors if there least one data character in the RX FIFO
read it otherwise it may stall the receiver.
This is recommended in the interrupt reset method in the table 23-246 of
the omap4 TRM.
Signed-off-by: Shubhrajyoti D <shubhrajyoti@ti.com>
---
- Tested on omap4sdp.
- pm tested hitting off in idle and suspend.
- v2 changes update the changelogs.
- Also remove the dummy check as FE , PE , BI and OE are the only
receiver errors.
drivers/tty/serial/omap-serial.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/drivers/tty/serial/omap-serial.c b/drivers/tty/serial/omap-serial.c
index a0d4460..4fea16b 100644
--- a/drivers/tty/serial/omap-serial.c
+++ b/drivers/tty/serial/omap-serial.c
@@ -334,6 +334,10 @@ static unsigned int check_modem_status(struct uart_omap_port *up)
static void serial_omap_rlsi(struct uart_omap_port *up, unsigned int lsr)
{
unsigned int flag;
+ unsigned char ch = 0;
+
+ if (likely(lsr & UART_LSR_DR))
+ ch = serial_in(up, UART_RX);
up->port.icount.rx++;
flag = TTY_NORMAL;
--
1.7.5.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH v2] serial: omap: fix the reciever line error case
2012-09-21 14:37 ` Shubhrajyoti D
@ 2012-09-21 16:01 ` Felipe Balbi
-1 siblings, 0 replies; 6+ messages in thread
From: Felipe Balbi @ 2012-09-21 16:01 UTC (permalink / raw)
To: Shubhrajyoti D; +Cc: linux-serial, linux-omap, linux-arm-kernel, Greg KH
[-- Attachment #1: Type: text/plain, Size: 1548 bytes --]
On Fri, Sep 21, 2012 at 08:07:19PM +0530, Shubhrajyoti D wrote:
> This patch does the following
> - In case of errors if there least one data character in the RX FIFO
> read it otherwise it may stall the receiver.
>
> This is recommended in the interrupt reset method in the table 23-246 of
> the omap4 TRM.
>
> Signed-off-by: Shubhrajyoti D <shubhrajyoti@ti.com>
FWIW:
Reviewed-by: Felipe Balbi <balbi@ti.com>
> ---
> - Tested on omap4sdp.
> - pm tested hitting off in idle and suspend.
> - v2 changes update the changelogs.
> - Also remove the dummy check as FE , PE , BI and OE are the only
> receiver errors.
>
> drivers/tty/serial/omap-serial.c | 4 ++++
> 1 files changed, 4 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/tty/serial/omap-serial.c b/drivers/tty/serial/omap-serial.c
> index a0d4460..4fea16b 100644
> --- a/drivers/tty/serial/omap-serial.c
> +++ b/drivers/tty/serial/omap-serial.c
> @@ -334,6 +334,10 @@ static unsigned int check_modem_status(struct uart_omap_port *up)
> static void serial_omap_rlsi(struct uart_omap_port *up, unsigned int lsr)
> {
> unsigned int flag;
> + unsigned char ch = 0;
> +
> + if (likely(lsr & UART_LSR_DR))
> + ch = serial_in(up, UART_RX);
>
> up->port.icount.rx++;
> flag = TTY_NORMAL;
> --
> 1.7.5.4
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
--
balbi
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH v2] serial: omap: fix the reciever line error case
@ 2012-09-21 16:01 ` Felipe Balbi
0 siblings, 0 replies; 6+ messages in thread
From: Felipe Balbi @ 2012-09-21 16:01 UTC (permalink / raw)
To: linux-arm-kernel
On Fri, Sep 21, 2012 at 08:07:19PM +0530, Shubhrajyoti D wrote:
> This patch does the following
> - In case of errors if there least one data character in the RX FIFO
> read it otherwise it may stall the receiver.
>
> This is recommended in the interrupt reset method in the table 23-246 of
> the omap4 TRM.
>
> Signed-off-by: Shubhrajyoti D <shubhrajyoti@ti.com>
FWIW:
Reviewed-by: Felipe Balbi <balbi@ti.com>
> ---
> - Tested on omap4sdp.
> - pm tested hitting off in idle and suspend.
> - v2 changes update the changelogs.
> - Also remove the dummy check as FE , PE , BI and OE are the only
> receiver errors.
>
> drivers/tty/serial/omap-serial.c | 4 ++++
> 1 files changed, 4 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/tty/serial/omap-serial.c b/drivers/tty/serial/omap-serial.c
> index a0d4460..4fea16b 100644
> --- a/drivers/tty/serial/omap-serial.c
> +++ b/drivers/tty/serial/omap-serial.c
> @@ -334,6 +334,10 @@ static unsigned int check_modem_status(struct uart_omap_port *up)
> static void serial_omap_rlsi(struct uart_omap_port *up, unsigned int lsr)
> {
> unsigned int flag;
> + unsigned char ch = 0;
> +
> + if (likely(lsr & UART_LSR_DR))
> + ch = serial_in(up, UART_RX);
>
> up->port.icount.rx++;
> flag = TTY_NORMAL;
> --
> 1.7.5.4
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo at vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
--
balbi
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20120921/716d4245/attachment.sig>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH v2] serial: omap: fix the reciever line error case
2012-09-21 14:37 ` Shubhrajyoti D
@ 2012-09-21 21:46 ` Kevin Hilman
-1 siblings, 0 replies; 6+ messages in thread
From: Kevin Hilman @ 2012-09-21 21:46 UTC (permalink / raw)
To: Shubhrajyoti D; +Cc: linux-serial, linux-omap, linux-arm-kernel
Shubhrajyoti D <shubhrajyoti@ti.com> writes:
> This patch does the following
> - In case of errors if there least one data character in the RX FIFO
> read it otherwise it may stall the receiver.
>
> This is recommended in the interrupt reset method in the table 23-246 of
> the omap4 TRM.
>
> Signed-off-by: Shubhrajyoti D <shubhrajyoti@ti.com>
> ---
> - Tested on omap4sdp.
> - pm tested hitting off in idle and suspend.
> - v2 changes update the changelogs.
> - Also remove the dummy check as FE , PE , BI and OE are the only
> receiver errors.
Tested-by: Kevin Hilman <khilman@ti.com>
This one also makes the regression I was seeing on 3530/Overo disappear.
Thanks,
Kevin
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH v2] serial: omap: fix the reciever line error case
@ 2012-09-21 21:46 ` Kevin Hilman
0 siblings, 0 replies; 6+ messages in thread
From: Kevin Hilman @ 2012-09-21 21:46 UTC (permalink / raw)
To: linux-arm-kernel
Shubhrajyoti D <shubhrajyoti@ti.com> writes:
> This patch does the following
> - In case of errors if there least one data character in the RX FIFO
> read it otherwise it may stall the receiver.
>
> This is recommended in the interrupt reset method in the table 23-246 of
> the omap4 TRM.
>
> Signed-off-by: Shubhrajyoti D <shubhrajyoti@ti.com>
> ---
> - Tested on omap4sdp.
> - pm tested hitting off in idle and suspend.
> - v2 changes update the changelogs.
> - Also remove the dummy check as FE , PE , BI and OE are the only
> receiver errors.
Tested-by: Kevin Hilman <khilman@ti.com>
This one also makes the regression I was seeing on 3530/Overo disappear.
Thanks,
Kevin
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2012-09-21 21:46 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-09-21 14:37 [PATCH v2] serial: omap: fix the reciever line error case Shubhrajyoti D
2012-09-21 14:37 ` Shubhrajyoti D
2012-09-21 16:01 ` Felipe Balbi
2012-09-21 16:01 ` Felipe Balbi
2012-09-21 21:46 ` Kevin Hilman
2012-09-21 21:46 ` Kevin Hilman
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.