summaryrefslogtreecommitdiff
path: root/include/linux/serial_core.h
diff options
context:
space:
mode:
authorPaul Gortmaker <paul.gortmaker@windriver.com>2012-03-09 04:12:11 +0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-03-10 00:47:56 +0400
commitdfe42443ea1d30c98db59b7b1f914bc147d31336 (patch)
tree479554def3fb2d90592f229e47f06e354aac1e35 /include/linux/serial_core.h
parent0d263a264c4b8376ccf33248f6fac873310e5e05 (diff)
downloadlinux-dfe42443ea1d30c98db59b7b1f914bc147d31336.tar.xz
serial: reduce number of indirections in 8250 code
The serial_8250_port struct contains within a serial_port struct and many times one or the other, or both are in scope within functions via a passed in arg, or via container_of. However there are a lot of cases where we have access directly to the port pointer, but yet go through the parent 8250_port structure instead to get it. These should just use the port struct directly. Similarly there are cases where it makes sense (from a code cleanliness point of view) to declare a local for the port struct, so we aren't going through the parent 8250_port struct repeatedly to get to it. We get a small reduction in text size, but it appears that gcc was smart enough to internally be doing most of this already, so the readability improvement is the larger gain. 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 'include/linux/serial_core.h')
0 files changed, 0 insertions, 0 deletions