aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/serial
diff options
context:
space:
mode:
authorAlan Cox <alan@lxorguk.ukuu.org.uk>2008-02-08 07:18:52 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2008-02-08 12:22:25 -0500
commit6f803cd08f4cfa40e3aa31ffc39777700c018e09 (patch)
tree4c8798afa63987733c693561afabee6c532918f0 /drivers/serial
parent5756ee99967d65fa8e14873d55cdf150659097ee (diff)
serial8250: coding style
Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/serial')
-rw-r--r--drivers/serial/8250.c19
1 files changed, 10 insertions, 9 deletions
diff --git a/drivers/serial/8250.c b/drivers/serial/8250.c
index b8a4bd94f51d..0b02757196b2 100644
--- a/drivers/serial/8250.c
+++ b/drivers/serial/8250.c
@@ -305,7 +305,7 @@ static inline int map_8250_out_reg(struct uart_8250_port *up, int offset)
305 return au_io_out_map[offset]; 305 return au_io_out_map[offset];
306} 306}
307 307
308#elif defined (CONFIG_SERIAL_8250_RM9K) 308#elif defined(CONFIG_SERIAL_8250_RM9K)
309 309
310static const u8 310static const u8
311 regmap_in[8] = { 311 regmap_in[8] = {
@@ -475,7 +475,7 @@ static inline void _serial_dl_write(struct uart_8250_port *up, int value)
475 serial_outp(up, UART_DLM, value >> 8 & 0xff); 475 serial_outp(up, UART_DLM, value >> 8 & 0xff);
476} 476}
477 477
478#if defined (CONFIG_SERIAL_8250_AU1X00) 478#if defined(CONFIG_SERIAL_8250_AU1X00)
479/* Au1x00 haven't got a standard divisor latch */ 479/* Au1x00 haven't got a standard divisor latch */
480static int serial_dl_read(struct uart_8250_port *up) 480static int serial_dl_read(struct uart_8250_port *up)
481{ 481{
@@ -492,7 +492,7 @@ static void serial_dl_write(struct uart_8250_port *up, int value)
492 else 492 else
493 _serial_dl_write(up, value); 493 _serial_dl_write(up, value);
494} 494}
495#elif defined (CONFIG_SERIAL_8250_RM9K) 495#elif defined(CONFIG_SERIAL_8250_RM9K)
496static int serial_dl_read(struct uart_8250_port *up) 496static int serial_dl_read(struct uart_8250_port *up)
497{ 497{
498 return (up->port.iotype == UPIO_RM9000) ? 498 return (up->port.iotype == UPIO_RM9000) ?
@@ -1185,8 +1185,8 @@ static void autoconfig_irq(struct uart_8250_port *up)
1185 1185
1186 irqs = probe_irq_on(); 1186 irqs = probe_irq_on();
1187 serial_outp(up, UART_MCR, 0); 1187 serial_outp(up, UART_MCR, 0);
1188 udelay (10); 1188 udelay(10);
1189 if (up->port.flags & UPF_FOURPORT) { 1189 if (up->port.flags & UPF_FOURPORT) {
1190 serial_outp(up, UART_MCR, 1190 serial_outp(up, UART_MCR,
1191 UART_MCR_DTR | UART_MCR_RTS); 1191 UART_MCR_DTR | UART_MCR_RTS);
1192 } else { 1192 } else {
@@ -1199,7 +1199,7 @@ static void autoconfig_irq(struct uart_8250_port *up)
1199 (void)serial_inp(up, UART_IIR); 1199 (void)serial_inp(up, UART_IIR);
1200 (void)serial_inp(up, UART_MSR); 1200 (void)serial_inp(up, UART_MSR);
1201 serial_outp(up, UART_TX, 0xFF); 1201 serial_outp(up, UART_TX, 0xFF);
1202 udelay (20); 1202 udelay(20);
1203 irq = probe_irq_off(irqs); 1203 irq = probe_irq_off(irqs);
1204 1204
1205 serial_outp(up, UART_MCR, save_mcr); 1205 serial_outp(up, UART_MCR, save_mcr);
@@ -1343,7 +1343,7 @@ receive_chars(struct uart_8250_port *up, unsigned int *status)
1343 1343
1344 uart_insert_char(&up->port, lsr, UART_LSR_OE, ch, flag); 1344 uart_insert_char(&up->port, lsr, UART_LSR_OE, ch, flag);
1345 1345
1346 ignore_char: 1346ignore_char:
1347 lsr = serial_inp(up, UART_LSR); 1347 lsr = serial_inp(up, UART_LSR);
1348 } while ((lsr & UART_LSR_DR) && (max_count-- > 0)); 1348 } while ((lsr & UART_LSR_DR) && (max_count-- > 0));
1349 spin_unlock(&up->port.lock); 1349 spin_unlock(&up->port.lock);
@@ -1633,7 +1633,8 @@ static void serial8250_backup_timeout(unsigned long data)
1633 serial_out(up, UART_IER, ier); 1633 serial_out(up, UART_IER, ier);
1634 1634
1635 /* Standard timer interval plus 0.2s to keep the port running */ 1635 /* Standard timer interval plus 0.2s to keep the port running */
1636 mod_timer(&up->timer, jiffies + poll_timeout(up->port.timeout) + HZ/5); 1636 mod_timer(&up->timer,
1637 jiffies + poll_timeout(up->port.timeout) + HZ / 5);
1637} 1638}
1638 1639
1639static unsigned int serial8250_tx_empty(struct uart_port *port) 1640static unsigned int serial8250_tx_empty(struct uart_port *port)
@@ -1844,7 +1845,7 @@ static int serial8250_startup(struct uart_port *port)
1844 up->timer.function = serial8250_backup_timeout; 1845 up->timer.function = serial8250_backup_timeout;
1845 up->timer.data = (unsigned long)up; 1846 up->timer.data = (unsigned long)up;
1846 mod_timer(&up->timer, jiffies + 1847 mod_timer(&up->timer, jiffies +
1847 poll_timeout(up->port.timeout) + HZ/5); 1848 poll_timeout(up->port.timeout) + HZ / 5);
1848 } 1849 }
1849 } 1850 }
1850 1851