aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/tty/serial/8250/8250.c
diff options
context:
space:
mode:
authorPaul Gortmaker <paul.gortmaker@windriver.com>2012-03-08 19:12:09 -0500
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-03-09 12:47:56 -0800
commit3f0ab32753b49ae7afc5b69e3f23152d92aa1f85 (patch)
tree9dd2dbb3be3fb3ae90ba3ead751b08aab8c8357e /drivers/tty/serial/8250/8250.c
parentserial: delete last unused traces of pausing I/O in 8250 (diff)
downloadlinux-dev-3f0ab32753b49ae7afc5b69e3f23152d92aa1f85.tar.xz
linux-dev-3f0ab32753b49ae7afc5b69e3f23152d92aa1f85.zip
serial: make 8250's serial_in shareable to other drivers.
Currently 8250.c has serial_in and serial_out as shortcuts to doing the port I/O. They are implemented as macros a ways down in the file. This isn't by accident, but is implicitly required, so cpp doesn't mangle other instances of the common string "serial_in", as it exists as a field in the port struct itself. The above mangling avoidance violates the principle of least surprise, and it also prevents the shortcuts from being relocated up to the top of file, or into 8250.h -- either being a better location than the current one. Move them to 8250.h so other 8250-like drivers can also use the shortcuts, and in the process, make the conflicting names go away by using static inlines instead of macros. The object file size remains unchanged with this modification. 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>
Diffstat (limited to 'drivers/tty/serial/8250/8250.c')
-rw-r--r--drivers/tty/serial/8250/8250.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/drivers/tty/serial/8250/8250.c b/drivers/tty/serial/8250/8250.c
index 9674eac5535c..4009e2438e40 100644
--- a/drivers/tty/serial/8250/8250.c
+++ b/drivers/tty/serial/8250/8250.c
@@ -482,11 +482,6 @@ serial_out_sync(struct uart_8250_port *up, int offset, int value)
}
}
-#define serial_in(up, offset) \
- (up->port.serial_in(&(up)->port, (offset)))
-#define serial_out(up, offset, value) \
- (up->port.serial_out(&(up)->port, (offset), (value)))
-
/* Uart divisor latch read */
static inline int _serial_dl_read(struct uart_8250_port *up)
{