mirror of
https://github.com/torvalds/linux.git
synced 2025-08-15 14:11:42 +02:00

As well as the last patch, pass struct btrfs_inode to the function and let it distinguish which data space it is working on in a later patch. There is no functional change with this commit. Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com> Signed-off-by: Naohiro Aota <naohiro.aota@wdc.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
31 lines
1.3 KiB
C
31 lines
1.3 KiB
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
|
|
#ifndef BTRFS_DELALLOC_SPACE_H
|
|
#define BTRFS_DELALLOC_SPACE_H
|
|
|
|
#include <linux/types.h>
|
|
|
|
struct extent_changeset;
|
|
struct btrfs_inode;
|
|
struct btrfs_fs_info;
|
|
|
|
int btrfs_alloc_data_chunk_ondemand(const struct btrfs_inode *inode, u64 bytes);
|
|
int btrfs_check_data_free_space(struct btrfs_inode *inode,
|
|
struct extent_changeset **reserved, u64 start, u64 len,
|
|
bool noflush);
|
|
void btrfs_free_reserved_data_space(struct btrfs_inode *inode,
|
|
struct extent_changeset *reserved, u64 start, u64 len);
|
|
void btrfs_delalloc_release_space(struct btrfs_inode *inode,
|
|
struct extent_changeset *reserved,
|
|
u64 start, u64 len, bool qgroup_free);
|
|
void btrfs_free_reserved_data_space_noquota(struct btrfs_inode *inode, u64 len);
|
|
void btrfs_delalloc_release_metadata(struct btrfs_inode *inode, u64 num_bytes,
|
|
bool qgroup_free);
|
|
int btrfs_delalloc_reserve_space(struct btrfs_inode *inode,
|
|
struct extent_changeset **reserved, u64 start, u64 len);
|
|
int btrfs_delalloc_reserve_metadata(struct btrfs_inode *inode, u64 num_bytes,
|
|
u64 disk_num_bytes, bool noflush);
|
|
void btrfs_delalloc_release_extents(struct btrfs_inode *inode, u64 num_bytes);
|
|
void btrfs_delalloc_shrink_extents(struct btrfs_inode *inode, u64 reserved_len, u64 new_len);
|
|
|
|
#endif /* BTRFS_DELALLOC_SPACE_H */
|