diff options
-rw-r--r-- | fs/inode.c | 4 | ||||
-rw-r--r-- | fs/ioctl.c | 2 |
2 files changed, 2 insertions, 4 deletions
diff --git a/fs/inode.c b/fs/inode.c index b4296bf62739..c03089421b6f 100644 --- a/fs/inode.c +++ b/fs/inode.c | |||
@@ -250,7 +250,7 @@ void clear_inode(struct inode *inode) | |||
250 | BUG_ON(inode->i_state & I_CLEAR); | 250 | BUG_ON(inode->i_state & I_CLEAR); |
251 | wait_on_inode(inode); | 251 | wait_on_inode(inode); |
252 | DQUOT_DROP(inode); | 252 | DQUOT_DROP(inode); |
253 | if (inode->i_sb && inode->i_sb->s_op->clear_inode) | 253 | if (inode->i_sb->s_op->clear_inode) |
254 | inode->i_sb->s_op->clear_inode(inode); | 254 | inode->i_sb->s_op->clear_inode(inode); |
255 | if (S_ISBLK(inode->i_mode) && inode->i_bdev) | 255 | if (S_ISBLK(inode->i_mode) && inode->i_bdev) |
256 | bd_forget(inode); | 256 | bd_forget(inode); |
@@ -1040,7 +1040,7 @@ static void generic_forget_inode(struct inode *inode) | |||
1040 | if (!(inode->i_state & (I_DIRTY|I_LOCK))) | 1040 | if (!(inode->i_state & (I_DIRTY|I_LOCK))) |
1041 | list_move(&inode->i_list, &inode_unused); | 1041 | list_move(&inode->i_list, &inode_unused); |
1042 | inodes_stat.nr_unused++; | 1042 | inodes_stat.nr_unused++; |
1043 | if (!sb || (sb->s_flags & MS_ACTIVE)) { | 1043 | if (sb->s_flags & MS_ACTIVE) { |
1044 | spin_unlock(&inode_lock); | 1044 | spin_unlock(&inode_lock); |
1045 | return; | 1045 | return; |
1046 | } | 1046 | } |
diff --git a/fs/ioctl.c b/fs/ioctl.c index ff61772ceedd..479c1038ed4a 100644 --- a/fs/ioctl.c +++ b/fs/ioctl.c | |||
@@ -67,8 +67,6 @@ static int file_ioctl(struct file *filp, unsigned int cmd, | |||
67 | return put_user(res, p); | 67 | return put_user(res, p); |
68 | } | 68 | } |
69 | case FIGETBSZ: | 69 | case FIGETBSZ: |
70 | if (inode->i_sb == NULL) | ||
71 | return -EBADF; | ||
72 | return put_user(inode->i_sb->s_blocksize, p); | 70 | return put_user(inode->i_sb->s_blocksize, p); |
73 | case FIONREAD: | 71 | case FIONREAD: |
74 | return put_user(i_size_read(inode) - filp->f_pos, p); | 72 | return put_user(i_size_read(inode) - filp->f_pos, p); |