2020-02-23 22:58:00

by Stephen Rothwell

[permalink] [raw]
Subject: linux-next: build warning after merge of the btrfs tree

Hi all,

After merging the btrfs tree, today's linux-next build (x86_64
allmodconfig) produced this warning:

fs/btrfs/check-integrity.c: In function 'btrfsic_process_superblock_dev_mirror':
fs/btrfs/check-integrity.c:916:9: warning: 'ret' may be used uninitialized in this function [-Wmaybe-uninitialized]
916 | return ret;
| ^~~

Introduced by commit

5a03d907a555 ("btrfs: remove buffer_heads form super block mirror integrity checking")

I think this is not a false positive since ret is only assigned is a
"goto out" is executed.

--
Cheers,
Stephen Rothwell


Attachments:
(No filename) (499.00 B)
OpenPGP digital signature

2020-02-24 14:37:54

by David Sterba

[permalink] [raw]
Subject: Re: linux-next: build warning after merge of the btrfs tree

On Mon, Feb 24, 2020 at 09:57:35AM +1100, Stephen Rothwell wrote:
> Hi all,
>
> After merging the btrfs tree, today's linux-next build (x86_64
> allmodconfig) produced this warning:
>
> fs/btrfs/check-integrity.c: In function 'btrfsic_process_superblock_dev_mirror':
> fs/btrfs/check-integrity.c:916:9: warning: 'ret' may be used uninitialized in this function [-Wmaybe-uninitialized]
> 916 | return ret;
> | ^~~
>
> Introduced by commit
>
> 5a03d907a555 ("btrfs: remove buffer_heads form super block mirror integrity checking")
>
> I think this is not a false positive since ret is only assigned is a
> "goto out" is executed.

Yes that sounds correct, will be fixed in next update, thanks.