]> www.infradead.org Git - users/jedix/linux-maple.git/commit
tty: serial: get rid of exit label from uart_set_info()
authorJiri Slaby (SUSE) <jirislaby@kernel.org>
Wed, 11 Dec 2024 07:49:32 +0000 (08:49 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 14 Dec 2024 14:40:16 +0000 (15:40 +0100)
commit4d0e56d571b8675e5a4863f394884c7db4387bcb
tree58b520e42336c2df47c228706381f51dbec2f10f
parente52ed2dd8287f7438c80e8e5e8c8bf14400cc1a2
tty: serial: get rid of exit label from uart_set_info()

The label is unneeded since 7ba2e769825f (tty: Split the serial_core
helpers for setserial into two). Until then, there was a lock held in
uart_set_info().

Now it is not, so we can remove the label. This involves reordering the
code, so that it is clear what values are returned, where and why. Until
now, it was really hard to follow.

The "change_port" part of the function is extracted into a separate
function in the next patch. This patch makes the transition there easier
too.

Signed-off-by: Jiri Slaby (SUSE) <jirislaby@kernel.org>
Link: https://lore.kernel.org/r/20241211074933.92973-3-jirislaby@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/serial_core.c