Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 275853
b: refs/heads/master
c: fadc0d8
h: refs/heads/master
i:
  275851: 44049db
v: v3
  • Loading branch information
David Sterba authored and Chris Mason committed Nov 20, 2011
1 parent dfa8869 commit 54654fe
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 52621cb6ed0e0e14358bb317bda7cd5fbd5c2a27
refs/heads/master: fadc0d8be4dfca80f6c568bc5874931893c6709b
6 changes: 4 additions & 2 deletions trunk/fs/btrfs/inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -6794,11 +6794,13 @@ static int btrfs_getattr(struct vfsmount *mnt,
struct dentry *dentry, struct kstat *stat)
{
struct inode *inode = dentry->d_inode;
u32 blocksize = inode->i_sb->s_blocksize;

generic_fillattr(inode, stat);
stat->dev = BTRFS_I(inode)->root->anon_dev;
stat->blksize = PAGE_CACHE_SIZE;
stat->blocks = (inode_get_bytes(inode) +
BTRFS_I(inode)->delalloc_bytes) >> 9;
stat->blocks = (ALIGN(inode_get_bytes(inode), blocksize) +
ALIGN(BTRFS_I(inode)->delalloc_bytes, blocksize)) >> 9;
return 0;
}

Expand Down

0 comments on commit 54654fe

Please sign in to comment.