mirror of
https://github.com/adulau/aha.git
synced 2024-12-28 03:36:19 +00:00
vfs: add missing unlock in sget()
In sget(), destroy_super(s) is called with s->s_umount held, which makes lockdep unhappy. Signed-off-by: Li Zefan <lizf@cn.fujitsu.com> Cc: Al Viro <viro@ZenIV.linux.org.uk> Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Paul Menage <menage@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
e5bc49ba74
commit
a3cfbb53b1
1 changed files with 4 additions and 1 deletions
|
@ -371,8 +371,10 @@ retry:
|
|||
continue;
|
||||
if (!grab_super(old))
|
||||
goto retry;
|
||||
if (s)
|
||||
if (s) {
|
||||
up_write(&s->s_umount);
|
||||
destroy_super(s);
|
||||
}
|
||||
return old;
|
||||
}
|
||||
}
|
||||
|
@ -387,6 +389,7 @@ retry:
|
|||
err = set(s, data);
|
||||
if (err) {
|
||||
spin_unlock(&sb_lock);
|
||||
up_write(&s->s_umount);
|
||||
destroy_super(s);
|
||||
return ERR_PTR(err);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue