* Re: test fix
[not found] <CAG21Q81aiFDj+UDw2LMipYvvJFh=mRVVE4bDEgEo3FXfR1nTfg@mail.gmail.com>
@ 2026-09-24 19:17 ` syzbot
0 siblings, 0 replies; only message in thread
From: syzbot @ 2026-09-24 19:17 UTC (permalink / raw)
To: igorpetindev; +Cc: igorpetindev, linux-kernel, syzkaller-bugs
> #syz test: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
This crash does not have a reproducer. I cannot test it.
> master
>
> diff --git a/drivers/tty/serial/serial_core.c b/drivers/tty/serial/serial_core.c
> index 95774b0f1484..030735da6b8c 100644
> --- a/drivers/tty/serial/serial_core.c
> +++ b/drivers/tty/serial/serial_core.c
> @@ -3210,8 +3210,15 @@ static void serial_core_remove_one_port(struct
> uart_driver *drv,
> /*
> * If the port is used as a console, unregister it
> */
> - if (uart_console(uport))
> + if (uart_console(uport)) {
> unregister_console(uport->cons);
> + port->console = false;
> + }
> +
> + guard(mutex)(&port->mutex);
> +
> + if (tty_port_initialized(port))
> + uart_shutdown(NULL, state);
>
> /*
> * Free the port IO and memory resources, if any.
> @@ -3227,7 +3234,6 @@ static void serial_core_remove_one_port(struct
> uart_driver *drv,
> uport->type = PORT_UNKNOWN;
> uport->port_dev = NULL;
>
> - guard(mutex)(&port->mutex);
> WARN_ON(atomic_dec_return(&state->refcount) < 0);
> wait_event(state->remove_wait, !atomic_read(&state->refcount));
> state->uart_port = NULL;
^ permalink raw reply [flat|nested] only message in thread