On Mon, Jul 14, 2014 at 01:29:02PM +0200, Lukáš Czerner wrote:
> On Sat, 12 Jul 2014, Dan Carpenter wrote:
> 
> > Date: Sat, 12 Jul 2014 12:34:09 +0300
> > From: Dan Carpenter <dan.carpen...@oracle.com>
> > To: Lukas Czerner <lczer...@redhat.com>, kbu...@01.org
> > Cc: Theodore Ts'o <ty...@mit.edu>, Dan Carpenter <dan.carpen...@oracle.com>
> > Subject: [ext4:dev 8/8] fs/ext4/indirect.c:1462 ext4_ind_remove_space() 
> > error:
> >      we previously assumed 'partial->bh' could be null (see line 1441)
> > 
> > tree:   git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4.git dev
> > head:   ae3a8a51e8906c552f8edfc7202c1b2bb6f73409
> > commit: ae3a8a51e8906c552f8edfc7202c1b2bb6f73409 [8/8] ext4: fix punch hole 
> > on files with indirect mapping
> > 
> > fs/ext4/indirect.c:1462 ext4_ind_remove_space() error: we previously 
> > assumed 'partial->bh' could be null (see line 1441)
> > fs/ext4/indirect.c:1474 ext4_ind_remove_space() error: we previously 
> > assumed 'partial2->bh' could be null (see line 1441)
> 
> Both of those are false positives, because if ( partial > chain )
> then partial->bh will always be set. But I am wondering how to
> silence the warning without introducing more pointless checks.
> 
> Maybe we can remove 
>               if ((partial->bh && partial2->bh) &&
> 
> and substitute it with
>               if (((partial > chain) && (partial2 > chain2)) &&
> 
> I'll retest and resend the patch.

Normally I just say we should leave false positives there.  Eventually
the tools will get smarter.

regards,
dan carpenter

_______________________________________________
kbuild mailing list
kbuild@lists.01.org
https://lists.01.org/mailman/listinfo/kbuild

Reply via email to