diff options
Diffstat (limited to 'drivers/serial/8250.c')
-rw-r--r-- | 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 0995430e4cf1..5443fcd38355 100644 --- a/drivers/serial/8250.c +++ b/drivers/serial/8250.c | |||
@@ -299,6 +299,7 @@ static inline int map_8250_out_reg(struct uart_8250_port *up, int offset) | |||
299 | 299 | ||
300 | static unsigned int serial_in(struct uart_8250_port *up, int offset) | 300 | static unsigned int serial_in(struct uart_8250_port *up, int offset) |
301 | { | 301 | { |
302 | unsigned int tmp; | ||
302 | offset = map_8250_in_reg(up, offset) << up->port.regshift; | 303 | offset = map_8250_in_reg(up, offset) << up->port.regshift; |
303 | 304 | ||
304 | switch (up->port.iotype) { | 305 | switch (up->port.iotype) { |
@@ -317,6 +318,13 @@ static unsigned int serial_in(struct uart_8250_port *up, int offset) | |||
317 | return __raw_readl(up->port.membase + offset); | 318 | return __raw_readl(up->port.membase + offset); |
318 | #endif | 319 | #endif |
319 | 320 | ||
321 | case UPIO_TSI: | ||
322 | if (offset == UART_IIR) { | ||
323 | tmp = readl((u32 *)(up->port.membase + UART_RX)); | ||
324 | return (cpu_to_le32(tmp) >> 8) & 0xff; | ||
325 | } else | ||
326 | return readb(up->port.membase + offset); | ||
327 | |||
320 | default: | 328 | default: |
321 | return inb(up->port.iobase + offset); | 329 | return inb(up->port.iobase + offset); |
322 | } | 330 | } |
@@ -346,6 +354,10 @@ serial_out(struct uart_8250_port *up, int offset, int value) | |||
346 | __raw_writel(value, up->port.membase + offset); | 354 | __raw_writel(value, up->port.membase + offset); |
347 | break; | 355 | break; |
348 | #endif | 356 | #endif |
357 | case UPIO_TSI: | ||
358 | if (!((offset == UART_IER) && (value & UART_IER_UUE))) | ||
359 | writeb(value, up->port.membase + offset); | ||
360 | break; | ||
349 | 361 | ||
350 | default: | 362 | default: |
351 | outb(value, up->port.iobase + offset); | 363 | outb(value, up->port.iobase + offset); |