diff options
author | Anand Jain <anand.jain@oracle.com> | 2021-02-11 06:25:15 +0100 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2021-04-19 17:25:14 +0200 |
commit | 05947ae18692736c665be4dfa5bb39a54c6b98ae (patch) | |
tree | dc2997bde8aeef74e9445fb4260331d9955f51c1 /fs/btrfs/extent-tree.c | |
parent | btrfs: replace open coded while loop with proper construct (diff) | |
download | linux-05947ae18692736c665be4dfa5bb39a54c6b98ae.tar.xz linux-05947ae18692736c665be4dfa5bb39a54c6b98ae.zip |
btrfs: unexport btrfs_extent_readonly() and make it static
btrfs_extent_readonly() is used by can_nocow_extent() in inode.c. So
move it from extent-tree.c to inode.c and declare it as static.
Signed-off-by: Anand Jain <anand.jain@oracle.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/extent-tree.c')
-rw-r--r-- | fs/btrfs/extent-tree.c | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c index 36a3c973fda1..2482b26b1971 100644 --- a/fs/btrfs/extent-tree.c +++ b/fs/btrfs/extent-tree.c @@ -2490,19 +2490,6 @@ int btrfs_dec_ref(struct btrfs_trans_handle *trans, struct btrfs_root *root, return __btrfs_mod_ref(trans, root, buf, full_backref, 0); } -int btrfs_extent_readonly(struct btrfs_fs_info *fs_info, u64 bytenr) -{ - struct btrfs_block_group *block_group; - int readonly = 0; - - block_group = btrfs_lookup_block_group(fs_info, bytenr); - if (!block_group || block_group->ro) - readonly = 1; - if (block_group) - btrfs_put_block_group(block_group); - return readonly; -} - static u64 get_alloc_profile_by_root(struct btrfs_root *root, int data) { struct btrfs_fs_info *fs_info = root->fs_info; |