Skip to content

Commit

Permalink
serial: delete useless void casts in 8250.c
Browse files Browse the repository at this point in the history
These might have worked some magic with an ancient gcc back in
1992, but "objdump --disassemble" on gcc 4.6 on x86-64 shows
identical output before and after this commit.  Send the casts
and their hysterical rasins to the bitbucket.

Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Acked-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Paul Gortmaker authored and Greg Kroah-Hartman committed Mar 9, 2012
1 parent 3f0ab32 commit 0d263a2
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions drivers/tty/serial/8250/8250.c
Original file line number Diff line number Diff line change
Expand Up @@ -1218,7 +1218,7 @@ static void autoconfig_irq(struct uart_8250_port *up)
ICP = (up->port.iobase & 0xfe0) | 0x1f;
save_ICP = inb_p(ICP);
outb_p(0x80, ICP);
(void) inb_p(ICP);
inb_p(ICP);
}

/* forget possible initially masked and pending IRQ */
Expand All @@ -1238,10 +1238,10 @@ static void autoconfig_irq(struct uart_8250_port *up)
UART_MCR_DTR | UART_MCR_RTS | UART_MCR_OUT2);
}
serial_out(up, UART_IER, 0x0f); /* enable all intrs */
(void)serial_in(up, UART_LSR);
(void)serial_in(up, UART_RX);
(void)serial_in(up, UART_IIR);
(void)serial_in(up, UART_MSR);
serial_in(up, UART_LSR);
serial_in(up, UART_RX);
serial_in(up, UART_IIR);
serial_in(up, UART_MSR);
serial_out(up, UART_TX, 0xFF);
udelay(20);
irq = probe_irq_off(irqs);
Expand Down Expand Up @@ -1973,10 +1973,10 @@ static int serial8250_startup(struct uart_port *port)
/*
* Clear the interrupt registers.
*/
(void) serial_in(up, UART_LSR);
(void) serial_in(up, UART_RX);
(void) serial_in(up, UART_IIR);
(void) serial_in(up, UART_MSR);
serial_in(up, UART_LSR);
serial_in(up, UART_RX);
serial_in(up, UART_IIR);
serial_in(up, UART_MSR);

/*
* At this point, there's no way the LSR could still be 0xff;
Expand Down Expand Up @@ -2152,7 +2152,7 @@ static int serial8250_startup(struct uart_port *port)
*/
icp = (up->port.iobase & 0xfe0) | 0x01f;
outb_p(0x80, icp);
(void) inb_p(icp);
inb_p(icp);
}

return 0;
Expand Down Expand Up @@ -2198,7 +2198,7 @@ static void serial8250_shutdown(struct uart_port *port)
* Read data port to reset things, and then unlink from
* the IRQ chain.
*/
(void) serial_in(up, UART_RX);
serial_in(up, UART_RX);

del_timer_sync(&up->timer);
up->timer.function = serial8250_timeout;
Expand Down

0 comments on commit 0d263a2

Please sign in to comment.