Re: [PATCH v1 2/2] tty: serial: 8250_dw: Keep init pinctrl state until first open

From: Linus Walleij

Date: Tue Aug 11 2026 - 02:48:18 EST


Hi Michal,

thanks for your patch!

On Mon, Aug 10, 2026 at 3:06 PM Michał Kardaś <mkmkl@xxxxxxxxxx> wrote:

> @@ -77,6 +78,7 @@ struct dw8250_data {
> unsigned int skip_autocfg:1;
> unsigned int uart_16550_compatible:1;
> unsigned int in_idle:1;
> + unsigned int in_init_state:1;

Side comment: why are these not bool?

> + if (!state) {
> pm_runtime_get_sync(port->dev);
> + if (d->in_init_state) {
> + d->in_init_state = false;
> + pinctrl_pm_select_default_state(port->dev);
> + }
> + }

As noticed in 0/2 don't use the default state for this, create and
use a custom but optional "online" state. It needs to be optional
so current users keep working without it.

Yours,
Linus Walleij