[PATCH v2 5/8] serial: 8250: Simplify serial8250_match_port()

From: Uwe Kleine-König (The Capable Hub)

Date: Tue Aug 04 2026 - 05:09:02 EST


For 8250 devices .iotype is never UPIO_BUS, so drop the respective if
branch.

Suggested-by: Hugo Villeneuve <hugo@xxxxxxxxxxx>
Link: https://lore.kernel.org/linux-serial/20260803152228.9e3cd296a41e68304b82a22a@xxxxxxxxxxx
Signed-off-by: Uwe Kleine-König (The Capable Hub) <u.kleine-koenig@xxxxxxxxxxxx>
---
drivers/tty/serial/8250/8250_core.c | 2 --
1 file changed, 2 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
index 3e53ef54ad7d..f113f8d5d158 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -649,8 +649,6 @@ static bool serial8250_match_port(const struct uart_port *port1,
return hub6_match_port(port1, port2);
else if (uart_iotype_mmio(port1->iotype))
return port1->mapbase == port2->mapbase;
- else if (port1->iotype == UPIO_BUS)
- return true;
else
return false;
}
--
2.55.0.11.g153666a7d9bb