wrappers for ->i_mutex access
parallel to mutex_{lock,unlock,trylock,is_locked,lock_nested}, inode_foo(inode) being mutex_foo(&inode->i_mutex). Please, use those for access to ->i_mutex; over the coming cycle ->i_mutex will become rwsem, with ->lookup() done with it held only shared. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
このコミットが含まれているのは:
@@ -769,7 +769,7 @@ static int fat_ioctl_readdir(struct inode *inode, struct file *file,
|
||||
|
||||
buf.dirent = dirent;
|
||||
buf.result = 0;
|
||||
mutex_lock(&inode->i_mutex);
|
||||
inode_lock(inode);
|
||||
buf.ctx.pos = file->f_pos;
|
||||
ret = -ENOENT;
|
||||
if (!IS_DEADDIR(inode)) {
|
||||
@@ -777,7 +777,7 @@ static int fat_ioctl_readdir(struct inode *inode, struct file *file,
|
||||
short_only, both ? &buf : NULL);
|
||||
file->f_pos = buf.ctx.pos;
|
||||
}
|
||||
mutex_unlock(&inode->i_mutex);
|
||||
inode_unlock(inode);
|
||||
if (ret >= 0)
|
||||
ret = buf.result;
|
||||
return ret;
|
||||
|
新しいイシューから参照
ユーザーをブロックする