Commit 9c5e1fb0 authored by David Sterba's avatar David Sterba

btrfs: remove duplicate name variable declarations

When running 'make W=2' there are a few reports where a variable of the
same name is declared in a nested block. In all the cases we can use the
one declared in the parent block, no problematic cases were found.
Reviewed-by: default avatarBoris Burkov <boris@bur.io>
Reviewed-by: default avatarAnand Jain <anand.jain@oracle.com>
Reviewed-by: default avatarNaohiro Aota <naohiro.aota@wdc.com>
Signed-off-by: default avatarDavid Sterba <dsterba@suse.com>
parent 56b7169f
...@@ -3507,7 +3507,6 @@ struct extent_buffer *btrfs_clone_extent_buffer(const struct extent_buffer *src) ...@@ -3507,7 +3507,6 @@ struct extent_buffer *btrfs_clone_extent_buffer(const struct extent_buffer *src)
for (int i = 0; i < num_folios; i++) { for (int i = 0; i < num_folios; i++) {
struct folio *folio = new->folios[i]; struct folio *folio = new->folios[i];
int ret;
ret = attach_extent_buffer_folio(new, folio, NULL); ret = attach_extent_buffer_folio(new, folio, NULL);
if (ret < 0) { if (ret < 0) {
...@@ -4589,8 +4588,7 @@ static void assert_eb_folio_uptodate(const struct extent_buffer *eb, int i) ...@@ -4589,8 +4588,7 @@ static void assert_eb_folio_uptodate(const struct extent_buffer *eb, int i)
return; return;
if (fs_info->nodesize < PAGE_SIZE) { if (fs_info->nodesize < PAGE_SIZE) {
struct folio *folio = eb->folios[0]; folio = eb->folios[0];
ASSERT(i == 0); ASSERT(i == 0);
if (WARN_ON(!btrfs_subpage_test_uptodate(fs_info, folio, if (WARN_ON(!btrfs_subpage_test_uptodate(fs_info, folio,
eb->start, eb->len))) eb->start, eb->len)))
......
...@@ -1617,10 +1617,8 @@ static noinline void submit_compressed_extents(struct btrfs_work *work, bool do_ ...@@ -1617,10 +1617,8 @@ static noinline void submit_compressed_extents(struct btrfs_work *work, bool do_
u64 alloc_hint = 0; u64 alloc_hint = 0;
if (do_free) { if (do_free) {
struct async_chunk *async_chunk;
struct async_cow *async_cow; struct async_cow *async_cow;
async_chunk = container_of(work, struct async_chunk, work);
btrfs_add_delayed_iput(async_chunk->inode); btrfs_add_delayed_iput(async_chunk->inode);
if (async_chunk->blkcg_css) if (async_chunk->blkcg_css)
css_put(async_chunk->blkcg_css); css_put(async_chunk->blkcg_css);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment