several fixes
Al Viro
maintainer Several fixes, including the brown paperbag one for -ELOOP breakage
in the last commit of yesterday pull. Please, pull from the usual place -git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6.git/ for-linus
Shortlog:
Al Viro (1):
fix follow_link() breakage
Christoph Hellwig (1):
prune back iprune_sem
Stephen Rothwell (1):
vfs: add nonconflicting values for O_PATH
Diffstat:
arch/alpha/include/asm/fcntl.h | 2 ++ arch/parisc/include/asm/fcntl.h | 2 ++ arch/sparc/include/asm/fcntl.h | 2 ++ fs/inode.c | 32 ++++++++++++++------------------ fs/namei.c | 7 +++---- 5 files changed, 23 insertions(+), 22 deletions(-)
Quoted 3 lines · Al Viro
Several fixes, including the brown paperbag one for
-ELOOPbreakage
in the last commit of yesterday pull. Please, pull from the usual place -git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6.git/for-linus
__fput doesn't need a cdev_put() for O_PATH handles.
--- fs/file_table.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
fs/file_table.c +3 -1
@@ -246,8 +246,10 @@ static void __fput(struct file *file) file->f_op->release (inode, file);security_file_free (file);ima_file_free (file); -if (unlikely (S_ISCHR (inode->i_mode) && inode->i_cdev !=NULL )) +if (unlikely (S_ISCHR (inode->i_mode) && inode->i_cdev !=NULL && + !(file->f_mode &FMODE_PATH ))) {cdev_put (inode->i_cdev); + }fops_put (file->f_op);put_pid (file->f_owner.pid);file_sb_list_del (file);
Quoted 2 lines · Miklos Szeredi
__fputdoesn't need acdev_put()forO_PATHhandles.
"doesn't need" or "must not have"?
Linus
Quoted 5 lines · Linus Torvalds
Quoted 2 lines · Miklos Szeredi
__fputdoesn't need acdev_put()forO_PATHhandles."doesn't need" or "must not have"?
It must not have one, otherwise refcounting will go astray.
That cdev_put() should really be moved into f_op->release(), but that would be quite a bit of work.
Thanks,
Miklos
Quoted 4 lines · Miklos Szeredi
Quoted 2 lines
"doesn't need" or "must not have"?
It must not have one, otherwise refcounting will go astray.
That's what I thought. The commit message just seemed to be off.
Quoted 2 lines
That
cdev_put()should really be moved intof_op->release(), but that would be quite a bit of work.
Yeah. Al?
Linus
Al Viro
maintainerQuoted 6 lines · Miklos Szeredi
Quoted 3 lines · Al Viro
Several fixes, including the brown paperbag one for
-ELOOPbreakage
in the last commit of yesterday pull. Please, pull from the usual place -git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6.git/for-linus
__fputdoesn't need acdev_put()forO_PATHhandles.
Good catch, thanks. Linus, do you want me to put that through vfs-2.6 or would you rather apply directly?
Al Viro
maintainerQuoted 4 lines · Linus Torvalds
Quoted 3 lines · Miklos Szeredi
Quoted 2 lines
"doesn't need" or "must not have"?
Quoted 8 lines
Quoted 1 line
It must not have one, otherwise refcounting will go astray.
That's what I thought. The commit message just seemed to be off.
Quoted 2 lines
That
cdev_put()should really be moved intof_op->release(), but that would be quite a bit of work.Yeah. Al?
In tree, with edited commit message... Please, pull from git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6.git/ for-linus (just one commit in that branch)
Quoted 2 lines · Al Viro
In tree, with edited commit message...
Well, not edited enough. It still talks about "not needing".
That thing "doesn't need" a cdev_put() the same way I "don't need" to be shot in the head.
But whatever. Pulled.
Linus