aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfs/inode.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/nfs/inode.c')
-rw-r--r--fs/nfs/inode.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c
index e8c143d182c4..bc9376ca86cd 100644
--- a/fs/nfs/inode.c
+++ b/fs/nfs/inode.c
@@ -277,10 +277,8 @@ nfs_fhget(struct super_block *sb, struct nfs_fh *fh, struct nfs_fattr *fattr)
277 * report the blocks in 512byte units 277 * report the blocks in 512byte units
278 */ 278 */
279 inode->i_blocks = nfs_calc_block_size(fattr->du.nfs3.used); 279 inode->i_blocks = nfs_calc_block_size(fattr->du.nfs3.used);
280 inode->i_blksize = inode->i_sb->s_blocksize;
281 } else { 280 } else {
282 inode->i_blocks = fattr->du.nfs2.blocks; 281 inode->i_blocks = fattr->du.nfs2.blocks;
283 inode->i_blksize = fattr->du.nfs2.blocksize;
284 } 282 }
285 nfsi->attrtimeo = NFS_MINATTRTIMEO(inode); 283 nfsi->attrtimeo = NFS_MINATTRTIMEO(inode);
286 nfsi->attrtimeo_timestamp = jiffies; 284 nfsi->attrtimeo_timestamp = jiffies;
@@ -443,7 +441,7 @@ static struct nfs_open_context *alloc_nfs_open_context(struct vfsmount *mnt, str
443{ 441{
444 struct nfs_open_context *ctx; 442 struct nfs_open_context *ctx;
445 443
446 ctx = (struct nfs_open_context *)kmalloc(sizeof(*ctx), GFP_KERNEL); 444 ctx = kmalloc(sizeof(*ctx), GFP_KERNEL);
447 if (ctx != NULL) { 445 if (ctx != NULL) {
448 atomic_set(&ctx->count, 1); 446 atomic_set(&ctx->count, 1);
449 ctx->dentry = dget(dentry); 447 ctx->dentry = dget(dentry);
@@ -969,10 +967,8 @@ static int nfs_update_inode(struct inode *inode, struct nfs_fattr *fattr)
969 * report the blocks in 512byte units 967 * report the blocks in 512byte units
970 */ 968 */
971 inode->i_blocks = nfs_calc_block_size(fattr->du.nfs3.used); 969 inode->i_blocks = nfs_calc_block_size(fattr->du.nfs3.used);
972 inode->i_blksize = inode->i_sb->s_blocksize;
973 } else { 970 } else {
974 inode->i_blocks = fattr->du.nfs2.blocks; 971 inode->i_blocks = fattr->du.nfs2.blocks;
975 inode->i_blksize = fattr->du.nfs2.blocksize;
976 } 972 }
977 973
978 if ((fattr->valid & NFS_ATTR_FATTR_V4) != 0 && 974 if ((fattr->valid & NFS_ATTR_FATTR_V4) != 0 &&
@@ -1134,8 +1130,7 @@ static int __init nfs_init_inodecache(void)
1134 1130
1135static void nfs_destroy_inodecache(void) 1131static void nfs_destroy_inodecache(void)
1136{ 1132{
1137 if (kmem_cache_destroy(nfs_inode_cachep)) 1133 kmem_cache_destroy(nfs_inode_cachep);
1138 printk(KERN_INFO "nfs_inode_cache: not all structures were freed\n");
1139} 1134}
1140 1135
1141/* 1136/*