Commit 4bcf787b503fa96c5a2f529ce15807dc670853ed from ext4/next [1]: "Add helper function for blkdev_issue_zeroout (sb_issue_discard)" ...lead to some rework of my initial patch, so here is v2 attached. As blkdev_issue_zeroout() has no more "flags", this has to be considered also in sb_issue_zeroout() and also in my v2 patch. [ block/blk-lib.c ] ... int blkdev_issue_zeroout(struct block_device *bdev, sector_t sector, sector_t nr_sects, gfp_t gfp_mask) ... Looks like this is compiling w/o errors in fs/ext4 tree. - Sedat - [1] http://git.kernel.org/?p=linux/kernel/git/tytso/ext4.git;a=commit;h=4bcf787b503fa96c5a2f529ce15807dc670853ed On Mon, Oct 18, 2010 at 9:13 AM, Jens Axboe <axboe@xxxxxxxxx> wrote: > On 2010-10-18 02:11, Sedat Dilek wrote: >> Hi, >> >> today, I pulled linux-2.6-block/for-next GIT branch [1] on top of >> Linus-tree (2.6.36-rc8-git3). >> >> Unfortunately, ext4/next GIT branch [2] is not "GIT-pull-able" on top >> of this local GIT repository. >> The cause for this is the removal of BLKDEV_IFL_BARRIER and >> BLKDEV_IFL_WAIT in linux-2.6-block/for-next. >> >> As there are few days left for 2.6.36-final, it would be great when >> ext4/next could be prepared to work with linux-2.6-block/for-next. >> Thanks in advance. > > The argument just has to be removed. linux-next has had a fixup > patch for this for a long time. > > -- > Jens Axboe > >
From aa1ff3009c3cf9975caf0baea9c1f75107f3eb1e Mon Sep 17 00:00:00 2001 From: Sedat Dilek <sedat.dilek@xxxxxxxxx> Date: Mon, 18 Oct 2010 13:01:07 +0200 Subject: [PATCH] ext4: Remove BLKDEV_IFL_WAIT and BLKDEV_IFL_BARRIER relicts These removals were necessary after pulling ext4/next GIT branch on top of linux-2.6-block/for-next. For more Details see also [1]. [1] http://marc.info/?l=linux-ext4&m=128736068809814&w=2 --- fs/ext4/extents.c | 2 +- fs/ext4/ialloc.c | 3 --- fs/ext4/resize.c | 4 ++-- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/fs/ext4/extents.c b/fs/ext4/extents.c index a0e6230..b738e6f 100644 --- a/fs/ext4/extents.c +++ b/fs/ext4/extents.c @@ -2546,7 +2546,7 @@ static int ext4_ext_zeroout(struct inode *inode, struct ext4_extent *ex) ee_pblock = ext_pblock(ex); ret = sb_issue_zeroout(inode->i_sb, ee_pblock, ee_len, - GFP_NOFS, BLKDEV_IFL_WAIT); + GFP_NOFS); if (ret > 0) ret = 0; diff --git a/fs/ext4/ialloc.c b/fs/ext4/ialloc.c index 87d228a..cc3a180 100644 --- a/fs/ext4/ialloc.c +++ b/fs/ext4/ialloc.c @@ -1238,7 +1238,6 @@ extern int ext4_init_inode_table(struct super_block *sb, ext4_group_t group, handle_t *handle; ext4_fsblk_t blk; int num, ret = 0, used_blks = 0; - unsigned long flags = BLKDEV_IFL_WAIT; /* This should not happen, but just to be sure check this */ if (sb->s_flags & MS_RDONLY) { @@ -1303,8 +1302,6 @@ extern int ext4_init_inode_table(struct super_block *sb, ext4_group_t group, ext4_debug("going to zero out inode table in group %d\n", group); - if (barrier) - flags |= BLKDEV_IFL_BARRIER; ret = sb_issue_zeroout(sb, blk, num, GFP_NOFS, flags); if (ret < 0) goto err_out; diff --git a/fs/ext4/resize.c b/fs/ext4/resize.c index 2f5e347..0f1f30c 100644 --- a/fs/ext4/resize.c +++ b/fs/ext4/resize.c @@ -229,7 +229,7 @@ static int setup_new_group_blocks(struct super_block *sb, ext4_debug("clear inode table blocks %#04llx -> %#04llx\n", block, sbi->s_itb_per_group); err = sb_issue_zeroout(sb, gdblocks + start + 1, reserved_gdb, - GFP_NOFS, BLKDEV_IFL_WAIT); + GFP_NOFS); if (err) goto exit_bh; @@ -245,7 +245,7 @@ static int setup_new_group_blocks(struct super_block *sb, ext4_debug("clear inode table blocks %#04llx -> %#04llx\n", block, sbi->s_itb_per_group); err = sb_issue_zeroout(sb, block, sbi->s_itb_per_group, - GFP_NOFS, BLKDEV_IFL_WAIT); + GFP_NOFS); if (err) goto exit_bh; -- 1.7.2.3
Index: linux-2.6/include/linux/blkdev.h =================================================================== --- linux-2.6.orig/include/linux/blkdev.h +++ linux-2.6/include/linux/blkdev.h @@ -892,12 +892,12 @@ static inline int sb_issue_discard(struc gfp_mask, flags); } static inline int sb_issue_zeroout(struct super_block *sb, sector_t block, - sector_t nr_blocks, gfp_t gfp_mask, unsigned long flags) + sector_t nr_blocks, gfp_t gfp_mask) { return blkdev_issue_zeroout(sb->s_bdev, block << (sb->s_blocksize_bits - 9), nr_blocks << (sb->s_blocksize_bits - 9), - gfp_mask, flags); + gfp_mask); } extern int blk_verify_command(unsigned char *cmd, fmode_t has_write_perm);
Index: linux-2.6/fs/ext4/ialloc.c =================================================================== --- linux-2.6.orig/fs/ext4/ialloc.c +++ linux-2.6/fs/ext4/ialloc.c @@ -1302,7 +1302,7 @@ extern int ext4_init_inode_table(struct ext4_debug("going to zero out inode table in group %d\n", group); - ret = sb_issue_zeroout(sb, blk, num, GFP_NOFS, flags); + ret = sb_issue_zeroout(sb, blk, num, GFP_NOFS); if (ret < 0) goto err_out;