diff options
author | David Howells <dhowells@redhat.com> | 2008-12-03 16:33:14 +0000 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-12-03 16:47:40 -0800 |
commit | 004b50f4ed2accb56069d56714a32484f8b83ec0 (patch) | |
tree | 7b8a8960972fed8e2c7bff027eb039e7e2d8d7f6 | |
parent | 8711cca2251f1fc3beb870a75ff847bb55225490 (diff) | |
download | op-kernel-dev-004b50f4ed2accb56069d56714a32484f8b83ec0.zip op-kernel-dev-004b50f4ed2accb56069d56714a32484f8b83ec0.tar.gz |
MN10300: Introduce barriers to replace removed volatiles in gdbstub 16550 driver
Introduce into the MN10300 gdbstub 16550 driver a couple of barrier() calls to
replace the removed volatility of the input/output index variables for the Rx
ring buffer. A previous patch added them into the on-chip serial port driver.
Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | arch/mn10300/kernel/gdb-io-serial.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/mn10300/kernel/gdb-io-serial.c b/arch/mn10300/kernel/gdb-io-serial.c index 9a6d4e8..11584c5 100644 --- a/arch/mn10300/kernel/gdb-io-serial.c +++ b/arch/mn10300/kernel/gdb-io-serial.c @@ -99,6 +99,7 @@ int gdbstub_io_rx_char(unsigned char *_ch, int nonblock) try_again: /* pull chars out of the buffer */ ix = gdbstub_rx_outp; + barrier(); if (ix == gdbstub_rx_inp) { if (nonblock) return -EAGAIN; @@ -110,6 +111,7 @@ int gdbstub_io_rx_char(unsigned char *_ch, int nonblock) ch = gdbstub_rx_buffer[ix++]; st = gdbstub_rx_buffer[ix++]; + barrier(); gdbstub_rx_outp = ix & 0x00000fff; if (st & UART_LSR_BI) { |