[PATCH v8 0/2] serial: core: fix baud rate fallback loop and baud_base overflow
From: Hui Peng
Date: Wed Oct 07 2026 - 06:02:23 EST
This series addresses two issues in serial core:
1. Division-by-zero WARN/Oops during baud rate fallback in uart_get_baud_rate().
2. 32-bit unsigned overflow in uart_set_info() when multiplying new_info->baud_base by 16.
All patches are ported to the latest tip of mainline (551c722f4080) and
dynamically verified in QEMU KVM with CONFIG_KASAN=y.
Changes in v8:
- 1/2: Rewrote commit description to detail the step-by-step loop iteration
progression (try == 0, try == 1, try == 2) as requested by Ilpo Järvinen
and Greg Kroah-Hartman.
- 2/2: Dropped secondary Fixes: 6eabce6608d6 tag per Hugo Villeneuve feedback.
Hui Peng (2):
serial: core: fix baud rate fallback in uart_get_baud_rate()
serial: core: reject baud_base values that overflow port->uartclk in
uart_set_info()
drivers/tty/serial/serial_core.c | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
--
2.47.3