提交 b845ff8f 编写于 作者: A Alexander Shishkin 提交者: Al Viro

cramfs: only unlock new inodes

Commit 77b8a75f introduced a warning at fs/inode.c:692 unlock_new_inode(),
caused by unlock_new_inode() being called on existing inodes as well.

This patch changes setup_inode() to only call unlock_new_inode() for I_NEW
inodes.
Signed-off-by: NAlexander Shishkin <virtuoso@slind.org>
Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
上级 f4ae2faa
......@@ -80,7 +80,7 @@ static struct inode *get_cramfs_inode(struct super_block *sb,
}
} else {
inode = iget_locked(sb, CRAMINO(cramfs_inode));
if (inode) {
if (inode && (inode->i_state & I_NEW)) {
setup_inode(inode, cramfs_inode);
unlock_new_inode(inode);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册