diff options
Diffstat (limited to 'fs/ramfs/inode.c')
-rw-r--r-- | fs/ramfs/inode.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/fs/ramfs/inode.c b/fs/ramfs/inode.c index b9677335cc8d..2faf4cdf61b0 100644 --- a/fs/ramfs/inode.c +++ b/fs/ramfs/inode.c | |||
@@ -58,7 +58,6 @@ struct inode *ramfs_get_inode(struct super_block *sb, int mode, dev_t dev) | |||
58 | inode->i_mode = mode; | 58 | inode->i_mode = mode; |
59 | inode->i_uid = current->fsuid; | 59 | inode->i_uid = current->fsuid; |
60 | inode->i_gid = current->fsgid; | 60 | inode->i_gid = current->fsgid; |
61 | inode->i_blksize = PAGE_CACHE_SIZE; | ||
62 | inode->i_blocks = 0; | 61 | inode->i_blocks = 0; |
63 | inode->i_mapping->a_ops = &ramfs_aops; | 62 | inode->i_mapping->a_ops = &ramfs_aops; |
64 | inode->i_mapping->backing_dev_info = &ramfs_backing_dev_info; | 63 | inode->i_mapping->backing_dev_info = &ramfs_backing_dev_info; |
@@ -76,7 +75,7 @@ struct inode *ramfs_get_inode(struct super_block *sb, int mode, dev_t dev) | |||
76 | inode->i_fop = &simple_dir_operations; | 75 | inode->i_fop = &simple_dir_operations; |
77 | 76 | ||
78 | /* directory inodes start off with i_nlink == 2 (for "." entry) */ | 77 | /* directory inodes start off with i_nlink == 2 (for "." entry) */ |
79 | inode->i_nlink++; | 78 | inc_nlink(inode); |
80 | break; | 79 | break; |
81 | case S_IFLNK: | 80 | case S_IFLNK: |
82 | inode->i_op = &page_symlink_inode_operations; | 81 | inode->i_op = &page_symlink_inode_operations; |
@@ -114,7 +113,7 @@ static int ramfs_mkdir(struct inode * dir, struct dentry * dentry, int mode) | |||
114 | { | 113 | { |
115 | int retval = ramfs_mknod(dir, dentry, mode | S_IFDIR, 0); | 114 | int retval = ramfs_mknod(dir, dentry, mode | S_IFDIR, 0); |
116 | if (!retval) | 115 | if (!retval) |
117 | dir->i_nlink++; | 116 | inc_nlink(dir); |
118 | return retval; | 117 | return retval; |
119 | } | 118 | } |
120 | 119 | ||