Re: [PATCH] tty: serial: meson_uart: Init port lock early

From: Andy Shevchenko
Date: Sun Jul 05 2020 - 07:22:25 EST


On Sun, Jul 05, 2020 at 11:28:56AM +0100, Marc Zyngier wrote:
> On 2020-07-05 11:07, Andy Shevchenko wrote:
> > On Sun, Jul 5, 2020 at 12:32 PM Marc Zyngier <maz@xxxxxxxxxx> 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@xxxxxxxxxxxxxxx/T/#m9255e2a7474b160e66c7060fca5323ca3df49cfd
>
> On its own, this patch doesn't seem to cure the issue (and it
> adds a compile-time warning due to unused flags).

Ah, sorry, I didn't compile it.
And after second though I think we simple need to initialise spin lock there.
Can you try below (compile-tested only):