@@ -379,7 +379,7 @@ static int caching_kthread(void *data)
379379 break ;
380380
381381 caching_ctl -> progress = last ;
382- btrfs_release_path (extent_root , path );
382+ btrfs_release_path (path );
383383 up_read (& fs_info -> extent_commit_sem );
384384 mutex_unlock (& caching_ctl -> mutex );
385385 if (btrfs_transaction_in_commit (fs_info ))
@@ -754,7 +754,7 @@ int btrfs_lookup_extent_info(struct btrfs_trans_handle *trans,
754754 atomic_inc (& head -> node .refs );
755755 spin_unlock (& delayed_refs -> lock );
756756
757- btrfs_release_path (root -> fs_info -> extent_root , path );
757+ btrfs_release_path (path );
758758
759759 mutex_lock (& head -> mutex );
760760 mutex_unlock (& head -> mutex );
@@ -934,7 +934,7 @@ static int convert_extent_item_v0(struct btrfs_trans_handle *trans,
934934 break ;
935935 }
936936 }
937- btrfs_release_path (root , path );
937+ btrfs_release_path (path );
938938
939939 if (owner < BTRFS_FIRST_FREE_OBJECTID )
940940 new_size += sizeof (* bi );
@@ -1042,7 +1042,7 @@ static noinline int lookup_extent_data_ref(struct btrfs_trans_handle *trans,
10421042 return 0 ;
10431043#ifdef BTRFS_COMPAT_EXTENT_TREE_V0
10441044 key .type = BTRFS_EXTENT_REF_V0_KEY ;
1045- btrfs_release_path (root , path );
1045+ btrfs_release_path (path );
10461046 ret = btrfs_search_slot (trans , root , & key , path , -1 , 1 );
10471047 if (ret < 0 ) {
10481048 err = ret ;
@@ -1080,7 +1080,7 @@ static noinline int lookup_extent_data_ref(struct btrfs_trans_handle *trans,
10801080 if (match_extent_data_ref (leaf , ref , root_objectid ,
10811081 owner , offset )) {
10821082 if (recow ) {
1083- btrfs_release_path (root , path );
1083+ btrfs_release_path (path );
10841084 goto again ;
10851085 }
10861086 err = 0 ;
@@ -1141,7 +1141,7 @@ static noinline int insert_extent_data_ref(struct btrfs_trans_handle *trans,
11411141 if (match_extent_data_ref (leaf , ref , root_objectid ,
11421142 owner , offset ))
11431143 break ;
1144- btrfs_release_path (root , path );
1144+ btrfs_release_path (path );
11451145 key .offset ++ ;
11461146 ret = btrfs_insert_empty_item (trans , root , path , & key ,
11471147 size );
@@ -1167,7 +1167,7 @@ static noinline int insert_extent_data_ref(struct btrfs_trans_handle *trans,
11671167 btrfs_mark_buffer_dirty (leaf );
11681168 ret = 0 ;
11691169fail :
1170- btrfs_release_path (root , path );
1170+ btrfs_release_path (path );
11711171 return ret ;
11721172}
11731173
@@ -1293,7 +1293,7 @@ static noinline int lookup_tree_block_ref(struct btrfs_trans_handle *trans,
12931293 ret = - ENOENT ;
12941294#ifdef BTRFS_COMPAT_EXTENT_TREE_V0
12951295 if (ret == - ENOENT && parent ) {
1296- btrfs_release_path (root , path );
1296+ btrfs_release_path (path );
12971297 key .type = BTRFS_EXTENT_REF_V0_KEY ;
12981298 ret = btrfs_search_slot (trans , root , & key , path , -1 , 1 );
12991299 if (ret > 0 )
@@ -1322,7 +1322,7 @@ static noinline int insert_tree_block_ref(struct btrfs_trans_handle *trans,
13221322 }
13231323
13241324 ret = btrfs_insert_empty_item (trans , root , path , & key , 0 );
1325- btrfs_release_path (root , path );
1325+ btrfs_release_path (path );
13261326 return ret ;
13271327}
13281328
@@ -1608,7 +1608,7 @@ static int lookup_extent_backref(struct btrfs_trans_handle *trans,
16081608 if (ret != - ENOENT )
16091609 return ret ;
16101610
1611- btrfs_release_path (root , path );
1611+ btrfs_release_path (path );
16121612 * ref_ret = NULL ;
16131613
16141614 if (owner < BTRFS_FIRST_FREE_OBJECTID ) {
@@ -1862,7 +1862,7 @@ static int __btrfs_inc_extent_ref(struct btrfs_trans_handle *trans,
18621862 __run_delayed_extent_op (extent_op , leaf , item );
18631863
18641864 btrfs_mark_buffer_dirty (leaf );
1865- btrfs_release_path (root -> fs_info -> extent_root , path );
1865+ btrfs_release_path (path );
18661866
18671867 path -> reada = 1 ;
18681868 path -> leave_spinning = 1 ;
@@ -2361,7 +2361,7 @@ static noinline int check_delayed_ref(struct btrfs_trans_handle *trans,
23612361 atomic_inc (& head -> node .refs );
23622362 spin_unlock (& delayed_refs -> lock );
23632363
2364- btrfs_release_path (root -> fs_info -> extent_root , path );
2364+ btrfs_release_path (path );
23652365
23662366 mutex_lock (& head -> mutex );
23672367 mutex_unlock (& head -> mutex );
@@ -2732,7 +2732,7 @@ static int write_one_cache_group(struct btrfs_trans_handle *trans,
27322732 bi = btrfs_item_ptr_offset (leaf , path -> slots [0 ]);
27332733 write_extent_buffer (leaf , & cache -> item , bi , sizeof (cache -> item ));
27342734 btrfs_mark_buffer_dirty (leaf );
2735- btrfs_release_path (extent_root , path );
2735+ btrfs_release_path (path );
27362736fail :
27372737 if (ret )
27382738 return ret ;
@@ -2785,7 +2785,7 @@ static int cache_save_setup(struct btrfs_block_group_cache *block_group,
27852785 inode = lookup_free_space_inode (root , block_group , path );
27862786 if (IS_ERR (inode ) && PTR_ERR (inode ) != - ENOENT ) {
27872787 ret = PTR_ERR (inode );
2788- btrfs_release_path (root , path );
2788+ btrfs_release_path (path );
27892789 goto out ;
27902790 }
27912791
@@ -2854,7 +2854,7 @@ static int cache_save_setup(struct btrfs_block_group_cache *block_group,
28542854out_put :
28552855 iput (inode );
28562856out_free :
2857- btrfs_release_path (root , path );
2857+ btrfs_release_path (path );
28582858out :
28592859 spin_lock (& block_group -> lock );
28602860 block_group -> disk_cache_state = dcs ;
@@ -4541,7 +4541,7 @@ static int __btrfs_free_extent(struct btrfs_trans_handle *trans,
45414541 NULL , refs_to_drop ,
45424542 is_data );
45434543 BUG_ON (ret );
4544- btrfs_release_path (extent_root , path );
4544+ btrfs_release_path (path );
45454545 path -> leave_spinning = 1 ;
45464546
45474547 key .objectid = bytenr ;
@@ -4580,7 +4580,7 @@ static int __btrfs_free_extent(struct btrfs_trans_handle *trans,
45804580 owner_objectid , 0 );
45814581 BUG_ON (ret < 0 );
45824582
4583- btrfs_release_path (extent_root , path );
4583+ btrfs_release_path (path );
45844584 path -> leave_spinning = 1 ;
45854585
45864586 key .objectid = bytenr ;
@@ -4650,7 +4650,7 @@ static int __btrfs_free_extent(struct btrfs_trans_handle *trans,
46504650 ret = btrfs_del_items (trans , extent_root , path , path -> slots [0 ],
46514651 num_to_del );
46524652 BUG_ON (ret );
4653- btrfs_release_path (extent_root , path );
4653+ btrfs_release_path (path );
46544654
46554655 if (is_data ) {
46564656 ret = btrfs_del_csums (trans , root , bytenr , num_bytes );
@@ -6480,7 +6480,7 @@ int btrfs_drop_snapshot(struct btrfs_root *root,
64806480 trans -> block_rsv = block_rsv ;
64816481 }
64826482 }
6483- btrfs_release_path (root , path );
6483+ btrfs_release_path (path );
64846484 BUG_ON (err );
64856485
64866486 ret = btrfs_del_root (trans , tree_root , & root -> root_key );
@@ -8580,7 +8580,7 @@ int btrfs_read_block_groups(struct btrfs_root *root)
85808580 memcpy (& cache -> key , & found_key , sizeof (found_key ));
85818581
85828582 key .objectid = found_key .objectid + found_key .offset ;
8583- btrfs_release_path (root , path );
8583+ btrfs_release_path (path );
85848584 cache -> flags = btrfs_block_group_flags (& cache -> item );
85858585 cache -> sectorsize = root -> sectorsize ;
85868586
@@ -8802,12 +8802,12 @@ int btrfs_remove_block_group(struct btrfs_trans_handle *trans,
88028802 if (ret < 0 )
88038803 goto out ;
88048804 if (ret > 0 )
8805- btrfs_release_path (tree_root , path );
8805+ btrfs_release_path (path );
88068806 if (ret == 0 ) {
88078807 ret = btrfs_del_item (trans , tree_root , path );
88088808 if (ret )
88098809 goto out ;
8810- btrfs_release_path (tree_root , path );
8810+ btrfs_release_path (path );
88118811 }
88128812
88138813 spin_lock (& root -> fs_info -> block_group_cache_lock );
0 commit comments