From: Josh Triplett Date: Fri, 29 Sep 2006 08:59:29 +0000 (-0700) Subject: [PATCH] fs: add lock annotation to grab_super X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=9c4dbee79d3f46608bec3ac80d392ce6415d2f90;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git [PATCH] fs: add lock annotation to grab_super grab_super gets called with sb_lock held, and releases it. Add a lock annotation to this function so that sparse can check callers for lock pairing, and so that sparse will not complain about this function since it intentionally uses the lock in this manner. Signed-off-by: Josh Triplett Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/fs/super.c b/fs/super.c index 5c4c94d5495e..6987824d0dce 100644 --- a/fs/super.c +++ b/fs/super.c @@ -199,7 +199,7 @@ EXPORT_SYMBOL(deactivate_super); * success, 0 if we had failed (superblock contents was already dead or * dying when grab_super() had been called). */ -static int grab_super(struct super_block *s) +static int grab_super(struct super_block *s) __releases(sb_lock) { s->s_count++; spin_unlock(&sb_lock);