Linux MIPS Architecture development
 help / color / mirror / Atom feed
From: Graham Gower <graham.gower@gmail.com>
To: linux-mips@linux-mips.org
Subject: [PATCH 2/3] 8250: serial driver changes for XBurst SoCs.
Date: Thu, 25 Feb 2010 17:00:50 +1030	[thread overview]
Message-ID: <4B86191A.1050406@gmail.com> (raw)
In-Reply-To: <4B861890.6090002@gmail.com>


Signed-off-by: Graham Gower <graham.gower@gmail.com>
---
 drivers/serial/8250.c |   12 ++++++++++++
 1 files changed, 12 insertions(+), 0 deletions(-)

diff --git a/drivers/serial/8250.c b/drivers/serial/8250.c
index e9b15c3..dfe6640 100644
--- a/drivers/serial/8250.c
+++ b/drivers/serial/8250.c
@@ -199,7 +199,11 @@ static const struct serial8250_config uart_config[] = {
 	[PORT_16550A] = {
 		.name		= "16550A",
 		.fifo_size	= 16,
+#ifndef CONFIG_XBURST
 		.tx_loadsz	= 16,
+#else
+		.tx_loadsz	= 8,
+#endif
 		.fcr		= UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
 		.flags		= UART_CAP_FIFO,
 	},
@@ -406,6 +410,10 @@ static unsigned int mem_serial_in(struct uart_port *p, int offset)
 static void mem_serial_out(struct uart_port *p, int offset, int value)
 {
 	offset = map_8250_out_reg(p, offset) << p->regshift;
+#if defined(CONFIG_XBURST)
+	if (offset == (UART_FCR << p->regshift))
+		value |= 0x10; /* set FCR.UUE */
+#endif
 	writeb(value, p->membase + offset);
 }
 
@@ -2354,6 +2362,10 @@ serial8250_set_termios(struct uart_port *port, struct ktermios *termios,
 	if (up->capabilities & UART_CAP_UUE)
 		up->ier |= UART_IER_UUE | UART_IER_RTOIE;
 
+#ifdef CONFIG_XBURST
+	up->ier |= UART_IER_RTOIE; /* Set this flag, or very slow */
+#endif
+
 	serial_out(up, UART_IER, up->ier);
 
 	if (up->capabilities & UART_CAP_EFR) {
-- 
1.6.4

  parent reply	other threads:[~2010-02-25  6:32 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-25  6:28 [PATCH 0/3] XBurst JZ4730 support Graham Gower
2010-02-25  6:29 ` [PATCH 1/3] Add " Graham Gower
2010-02-25  6:30 ` Graham Gower [this message]
2010-02-25  6:31 ` [PATCH 3/3] net: add driver for JZ4730 ethernet controller Graham Gower
2010-02-25  7:52 ` [PATCH 0/3] XBurst JZ4730 support Florian Fainelli
2010-02-25 21:12   ` Graham Gower
2010-02-26  1:51     ` Lars-Peter Clausen
2010-02-26  3:34       ` Graham Gower
2010-02-26 11:41         ` blast_dcache32 problem with PREEMPT kernel Anoop P.A.
2010-02-26 11:41           ` Anoop P.A.

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4B86191A.1050406@gmail.com \
    --to=graham.gower@gmail.com \
    --cc=linux-mips@linux-mips.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox