Commit ea0547ed authored by Deepak Saxena's avatar Deepak Saxena Committed by Linus Torvalds

[PATCH] Add support for word-length UART registers

UARTS on several Intel IXP2000 systems are connected in such a way that
they can only be addressed using full word accesses instead of bytes.
Following patch adds a UPIO_MEM32 io-type to identify these UARTs.
Signed-off-by: default avatarDeepak Saxena <dsaxena@plexity.net>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 8d17d331
......@@ -188,6 +188,9 @@ static _INLINE_ unsigned int serial_in(struct uart_8250_port *up, int offset)
case UPIO_MEM:
return readb(up->port.membase + offset);
case UPIO_MEM32:
return readl(up->port.membase + offset);
default:
return inb(up->port.iobase + offset);
}
......@@ -208,6 +211,10 @@ serial_out(struct uart_8250_port *up, int offset, int value)
writeb(value, up->port.membase + offset);
break;
case UPIO_MEM32:
writel(value, up->port.membase + offset);
break;
default:
outb(value, up->port.iobase + offset);
}
......
......@@ -1978,6 +1978,7 @@ uart_report_port(struct uart_driver *drv, struct uart_port *port)
printk("I/O 0x%x offset 0x%x", port->iobase, port->hub6);
break;
case UPIO_MEM:
case UPIO_MEM32:
printk("MMIO 0x%lx", port->mapbase);
break;
}
......
......@@ -176,6 +176,7 @@ struct uart_port {
#define UPIO_PORT (0)
#define UPIO_HUB6 (1)
#define UPIO_MEM (2)
#define UPIO_MEM32 (3)
unsigned int read_status_mask; /* driver specific */
unsigned int ignore_status_mask; /* driver specific */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment