Re: drivers/tty/serial/pmac_zilog.c:255:36: sparse: sparse: context imbalance in 'pmz_receive_chars' - unexpected unlock

From: Johan Hovold
Date: Thu Jul 23 2020 - 08:37:34 EST


On Thu, Jul 23, 2020 at 03:26:54PM +0300, Andy Shevchenko wrote:
> On Thu, Jul 23, 2020 at 3:19 PM Johan Hovold <johan@xxxxxxxxxx> wrote:
> >
> > On Thu, Jul 23, 2020 at 05:29:14PM +0800, kernel test robot wrote:
> > > tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> > > head: d15be546031cf65a0fc34879beca02fd90fe7ac7
> > > commit: 08d5470308ac3598e7709d08b8979ce6e9de8da2 serial: core: fix sysrq overhead regression
> > > date: 4 weeks ago
> > > config: m68k-randconfig-s032-20200723 (attached as .config)
> > > compiler: m68k-linux-gcc (GCC) 9.3.0
> > > reproduce:
> > > wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
> > > chmod +x ~/bin/make.cross
> > > # apt-get install sparse
> > > # sparse version: v0.6.2-93-g4c6cbe55-dirty
> > > git checkout 08d5470308ac3598e7709d08b8979ce6e9de8da2
> > > # save the attached .config to linux build tree
> > > COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=m68k
> > >
> > > If you fix the issue, kindly add following tag as appropriate
> > > Reported-by: kernel test robot <lkp@xxxxxxxxx>
> > >
> > >
> > > sparse warnings: (new ones prefixed by >>)
> > >
> > > >> drivers/tty/serial/pmac_zilog.c:255:36: sparse: sparse: context imbalance in 'pmz_receive_chars' - unexpected unlock
> >
> > This warning is far from new,
>
> I suspect it's a new sparse and kbuildbot that decided to unveil old sins.

Possibly.

> > but let's add the missing annotation
> > nonetheless:
> >
> > https://lore.kernel.org/r/20200723121423.24217-1-johan@xxxxxxxxxx
>
> Feel free to add Reviewed-by: Andy Shevchenko
> <andy.shevchenko@xxxxxxxxx> to them.

Thanks, and sorry I missed this before sending a v2 with the missing
ampersands added. It's better if you reply to the cover letter so Greg's
tooling will pick it up:

https://lore.kernel.org/r/20200723123327.5843-1-johan@xxxxxxxxxx

Johan