lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHp75VfFNO=oqHX9EeNdVgcQUfu7RBr6SDTWi3XF4gSQNjqzUw@mail.gmail.com>
Date:   Sun, 5 Jul 2020 13:07:18 +0300
From:   Andy Shevchenko <andy.shevchenko@...il.com>
To:     Marc Zyngier <maz@...nel.org>
Cc:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Kevin Hilman <khilman@...libre.com>,
        "open list:SERIAL DRIVERS" <linux-serial@...r.kernel.org>,
        linux-amlogic@...ts.infradead.org,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        kernel-team@...roid.com,
        Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Subject: Re: [PATCH] tty: serial: meson_uart: Init port lock early

On Sun, Jul 5, 2020 at 12:32 PM Marc Zyngier <maz@...nel.org> wrote:
>
> The meson UART driver triggers a lockdep splat at boot time, due
> to the new expectation that the driver has to initialize the
> per-port spinlock itself.
>
> It remains unclear why a double initialization of the port
> spinlock is a desirable outcome, but in the meantime let's
> fix the splat.
>

Thanks!

Can you test patch from [1] if it helps and doesn't break anything in your case?

[1]: https://lore.kernel.org/linux-serial/20200217114016.49856-1-andriy.shevchenko@linux.intel.com/T/#m9255e2a7474b160e66c7060fca5323ca3df49cfd

> Fixes: a3cb39d258ef ("serial: core: Allow detach and attach serial device for console")
> Cc: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
> Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
> Signed-off-by: Marc Zyngier <maz@...nel.org>
> ---
>  drivers/tty/serial/meson_uart.c | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/drivers/tty/serial/meson_uart.c b/drivers/tty/serial/meson_uart.c
> index d2c08b760f83..386e39c90628 100644
> --- a/drivers/tty/serial/meson_uart.c
> +++ b/drivers/tty/serial/meson_uart.c
> @@ -759,6 +759,9 @@ static int meson_uart_probe(struct platform_device *pdev)
>         if (ret)
>                 return ret;
>
> +       /* Init the spinlock early in case this is the console */
> +       spin_lock_init(&port->lock);
> +
>         port->iotype = UPIO_MEM;
>         port->mapbase = res_mem->start;
>         port->mapsize = resource_size(res_mem);
> --
> 2.26.2
>


-- 
With Best Regards,
Andy Shevchenko

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ