udf: update inode's iblock count when allocating new block
PATCH 3/6 udf: update inode's iblock count when allocating new block
From: Namjae Jeon <[email protected]>
Currently, du will show wrong block count. This patch fix it.
--- fs/udf/inode.c | 2 ++ 1 file changed, 2 insertions(+)
fs/udf/inode.c +2 -0
@@ -775,6 +775,8 @@ static sector_t inode_getblk(struct inode *inode, sector_t block,if (isBeyondEOF) iinfo->i_lenExtents += inode->i_sb->s_blocksize; } +/* update inode's iblocks */ + inode->i_blocks += (1 << (inode->i_sb->s_blocksize_bits -9 ));/* if the extent the requsted block is located in contains multiple * blocks, split the extent into at most three extents. blocks prior
Signature · 1 line
1.7.9.5
Quoted 3 lines · Namjae Jeon
From: Namjae Jeon <[email protected]>
Currently, du will show wrong block count. This patch fix it.
This should be fixed by commit fd4287dbc07763595c1e74edbb6520092290185c.
Have you tested with newish kernel? If recent kernel still has an issue, can you provide a test case? Thanks!
Honza
Quoted 23 lines
Signed-off-by Namjae Jeon <[email protected]>Signed-off-by Ashish Sangwan <[email protected]>--- fs/udf/inode.c | 2 ++ 1 file changed, 2 insertions(+)fs/udf/inode.c +2
-0@@ -775,6 +775,8 @@ static sector_t inode_getblk(struct inode *inode, sector_t block,if (isBeyondEOF) iinfo->i_lenExtents += inode->i_sb->s_blocksize; } +/* update inode's iblocks */ + inode->i_blocks += (1 << (inode->i_sb->s_blocksize_bits -9 ));/* if the extent the requsted block is located in contains multiple * blocks, split the extent into at most three extents. blocks prior Signature · 1 line
1.7.9.5
Signature · 2 lines
Jan Kara <[email protected]> SUSE Labs, CR
2012/10/12 Jan Kara <[email protected]>:
Quoted 7 lines · Namjae Jeon
Quoted 3 lines
From: Namjae Jeon <[email protected]>
Currently, du will show wrong block count. This patch fix it.
This should be fixed by commit
fd4287dbc07763595c1e74edbb6520092290185c.
Have you tested with newish kernel? If recent kernel still has an issue, can you provide a test case? Thanks!
Hi. Jan.
You're right. There is no issue with latest kernel. Plz ignore this patch.
Thanks a lot!
Quoted 29 lines
Honza
Quoted 21 lines
Signed-off-by Namjae Jeon <[email protected]>Signed-off-by Ashish Sangwan <[email protected]>--- fs/udf/inode.c | 2 ++ 1 file changed, 2 insertions(+)fs/udf/inode.c +2
-1@@ -775,6 +775,8 @@ static sector_t inode_getblk(struct inode *inode, sector_t block,if (isBeyondEOF) iinfo->i_lenExtents += inode->i_sb->s_blocksize; } +/* update inode's iblocks */ + inode->i_blocks += (1 << (inode->i_sb->s_blocksize_bits -9 ));/* if the extent the requsted block is located in contains multiple * blocks, split the extent into at most three extents. blocks prior -- Quoted 2 lines
1.7.9.5
--
Jan Kara <[email protected]>
SUSE Labs, CR