aboutsummaryrefslogtreecommitdiff
path: root/fs/ext2/balloc.c
diff options
context:
space:
mode:
authorGravatar Ye Bin <yebin10@huawei.com> 2023-08-15 19:26:10 +0800
committerGravatar Jan Kara <jack@suse.cz> 2023-08-16 17:42:42 +0200
commitb450159d0903b06ebea121a010ab9c424b67c408 (patch)
treeb75bd71872b7fdb0c817601796e1f8adb434c64a /fs/ext2/balloc.c
parentext2: remove ext2_new_block() (diff)
downloadlinux-b450159d0903b06ebea121a010ab9c424b67c408.tar.gz
linux-b450159d0903b06ebea121a010ab9c424b67c408.tar.bz2
linux-b450159d0903b06ebea121a010ab9c424b67c408.zip
ext2: introduce new flags argument for ext2_new_blocks()
This patch introduces a new flags argument for ext2_new_blocks() and also a new EXT2_ALLOC_NORESERVE flag. Signed-off-by: Ye Bin <yebin10@huawei.com> Message-Id: <20230815112612.221145-3-yebin10@huawei.com> Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'fs/ext2/balloc.c')
-rw-r--r--fs/ext2/balloc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/ext2/balloc.c b/fs/ext2/balloc.c
index ddaa823fc7f5..a9648c3137db 100644
--- a/fs/ext2/balloc.c
+++ b/fs/ext2/balloc.c
@@ -1195,6 +1195,7 @@ int ext2_data_block_valid(struct ext2_sb_info *sbi, ext2_fsblk_t start_blk,
* @goal: given target block(filesystem wide)
* @count: target number of blocks to allocate
* @errp: error code
+ * @flags: allocate flags
*
* ext2_new_blocks uses a goal block to assist allocation. If the goal is
* free, or there is a free block within 32 blocks of the goal, that block
@@ -1204,7 +1205,7 @@ int ext2_data_block_valid(struct ext2_sb_info *sbi, ext2_fsblk_t start_blk,
* This function also updates quota and i_blocks field.
*/
ext2_fsblk_t ext2_new_blocks(struct inode *inode, ext2_fsblk_t goal,
- unsigned long *count, int *errp)
+ unsigned long *count, int *errp, unsigned int flags)
{
struct buffer_head *bitmap_bh = NULL;
struct buffer_head *gdp_bh;