From: Mike Marshall Date: Wed, 5 Aug 2015 17:46:28 +0000 (-0400) Subject: Orangefs: use inode_set_bytes for directories X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=f0566532fe19c7f75a3c0c908152ea0e24e6ead2;p=linux-beck.git Orangefs: use inode_set_bytes for directories Signed-off-by: Mike Marshall --- diff --git a/fs/orangefs/pvfs2-utils.c b/fs/orangefs/pvfs2-utils.c index 6eecb1861aca..11ee073ecd19 100644 --- a/fs/orangefs/pvfs2-utils.c +++ b/fs/orangefs/pvfs2-utils.c @@ -162,12 +162,11 @@ static int copy_attributes_to_inode(struct inode *inode, } /*FALLTHRU*/ default: + inode->i_size = PAGE_CACHE_SIZE; + pvfs2_lock_inode(inode); - inode->i_bytes = (unsigned short)PAGE_CACHE_SIZE; - inode->i_blocks = (unsigned long)(PAGE_CACHE_SIZE / 512); + inode_set_bytes(inode, inode->i_size); pvfs2_unlock_inode(inode); - - inode->i_size = PAGE_CACHE_SIZE; break; }