serial: 8250_fintek: Refactoring read/write method
authorJi-Ze Hong (Peter Hong) <hpeter@gmail.com>
Tue, 4 Oct 2016 08:27:59 +0000 (16:27 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 27 Oct 2016 14:28:16 +0000 (16:28 +0200)
commitf1232ac229cc078206a72ca365c3526e37ea1ae5
tree31fc3e71e9870e17698f41c696c65f1860e574bf
parentfea6dd14868aa8f954804cf4a629b6af3e47c484
serial: 8250_fintek: Refactoring read/write method

If we need to access SuperIO registers, It should write register offset
to base_addr and read/write value to base_addr + 1 to perform read/write.
We can make it more simply with write/read functions.

This patch add sio_read_reg()/sio_write_reg()/sio_write_mask_reg() to
reduce SuperIO register operation with lot of outb()/inb().

Signed-off-by: Ji-Ze Hong (Peter Hong) <hpeter+linux_kernel@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/8250/8250_fintek.c