diff options
Diffstat (limited to 'mm/shmem.c')
-rw-r--r-- | mm/shmem.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/mm/shmem.c b/mm/shmem.c index 4c5e68e4e9ae..1e43c8a865ba 100644 --- a/mm/shmem.c +++ b/mm/shmem.c | |||
@@ -1780,6 +1780,7 @@ static int shmem_rmdir(struct inode *dir, struct dentry *dentry) | |||
1780 | if (!simple_empty(dentry)) | 1780 | if (!simple_empty(dentry)) |
1781 | return -ENOTEMPTY; | 1781 | return -ENOTEMPTY; |
1782 | 1782 | ||
1783 | dentry->d_inode->i_nlink--; | ||
1783 | dir->i_nlink--; | 1784 | dir->i_nlink--; |
1784 | return shmem_unlink(dir, dentry); | 1785 | return shmem_unlink(dir, dentry); |
1785 | } | 1786 | } |
@@ -2102,6 +2103,7 @@ static int shmem_fill_super(struct super_block *sb, | |||
2102 | sb->s_blocksize_bits = PAGE_CACHE_SHIFT; | 2103 | sb->s_blocksize_bits = PAGE_CACHE_SHIFT; |
2103 | sb->s_magic = TMPFS_MAGIC; | 2104 | sb->s_magic = TMPFS_MAGIC; |
2104 | sb->s_op = &shmem_ops; | 2105 | sb->s_op = &shmem_ops; |
2106 | sb->s_time_gran = 1; | ||
2105 | 2107 | ||
2106 | inode = shmem_get_inode(sb, S_IFDIR | mode, 0); | 2108 | inode = shmem_get_inode(sb, S_IFDIR | mode, 0); |
2107 | if (!inode) | 2109 | if (!inode) |