serial: 8250_pci: Refactor the loop in pci_ite887x_init()
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Fri, 22 Oct 2021 13:51:45 +0000 (16:51 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 26 Oct 2021 06:41:00 +0000 (08:41 +0200)
commit35b4f17231923e2f64521bdf7a2793ce2c3c74a6
treeec2a7be1f36ae288dfd3f8a497f30b7b0b5f56c5
parent7c0408d805797178f075f33d0f705a1c6ef76c82
serial: 8250_pci: Refactor the loop in pci_ite887x_init()

The loop can be refactored by using ARRAY_SIZE() instead of NULL terminator.
This reduces code base and makes it easier to read and understand.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Jiri Slaby <jslaby@kernel.org>
Link: https://lore.kernel.org/r/20211022135147.70965-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/8250/8250_pci.c