Skip to contentSkip to conversation

linux-next: build warning after merge of the btrfs-kdave tree

DISCUSSION Stephen Rothwell 2 participants 3 messages Nov 28, 2016 – Dec 14, 2016 Linux-next tree

lore
Share & tools
lore
#0 lore raw

Hi David,

After merging the btrfs-kdave tree, today's linux-next build (powerpc ppc64_defconfig) produced this warning:

fs/btrfs/inode.c: In function 'run_delalloc_range':
fs/btrfs/inode.c:1219:9: warning: 'cur_end' may be used uninitialized in this function [-Wmaybe-uninitialized]

   start = cur_end + 1;
         ^
fs/btrfs/inode.c:1172:6: note: 'cur_end' was declared here
  u64 cur_end;
      ^

Introduced by commit

cow_file_range_async ("btrfs: Introduce COMPRESS reserve type to fix false enospc for compression")

Presumably a false positive because ASSERT(0) panics?

Signature · 2 lines
Cheers,
Stephen Rothwell
#1 lore raw

Hi David,

Quoted 12 lines · On Mon, 28 Nov 2016 11:02:30 +1100 Stephen Rothwell <[email protected]>…

After merging the btrfs-kdave tree, today's linux-next build (powerpc ppc64_defconfig) produced this warning:

fs/btrfs/inode.c: In function 'run_delalloc_range':
fs/btrfs/inode.c:1219:9: warning: 'cur_end' may be used uninitialized in this function [-Wmaybe-uninitialized]

   start = cur_end + 1;
         ^
fs/btrfs/inode.c:1172:6: note: 'cur_end' was declared here
  u64 cur_end;
      ^
Quoted 5 lines

Introduced by commit

cow_file_range_async ("btrfs: Introduce COMPRESS reserve type to fix false enospc for compression")

Presumably a false positive because ASSERT(0) panics?

Actually it does not if CONFIG_BTRFS_ASSERT is not set (which it isn't for the above build), so this is not a false positive. I am still seeing this.

Signature · 2 lines
Cheers,
Stephen Rothwell
#2 lore raw
Quoted 17 lines · Stephen Rothwell

Hi David,

Quoted 14 lines · On Mon, 28 Nov 2016 11:02:30 +1100 Stephen Rothwell <[email protected]>…

After merging the btrfs-kdave tree, today's linux-next build (powerpc ppc64_defconfig) produced this warning:

fs/btrfs/inode.c: In function 'run_delalloc_range':
fs/btrfs/inode.c:1219:9: warning: 'cur_end' may be used uninitialized in this function [-Wmaybe-uninitialized]

   start = cur_end + 1;
         ^
fs/btrfs/inode.c:1172:6: note: 'cur_end' was declared here
  u64 cur_end;
      ^

Introduced by commit

Quoted 7 lines
Quoted 3 lines

cow_file_range_async ("btrfs: Introduce COMPRESS reserve type to fix false enospc for compression")

Presumably a false positive because ASSERT(0) panics?

Actually it does not if CONFIG_BTRFS_ASSERT is not set (which it isn't for the above build), so this is not a false positive. I am still seeing this.

Sorry for late reply. I've updatd the for-next branch now, the patches introducing the warning have been removed temporarily. Arnd Bergmann sent a patch to fix the warning, I'll make sure to include it so the warning does not reappear.