From: Frederik Deweerdt <deweerdt@free.fr>
To: Andrew Morton <akpm@osdl.org>
Cc: linux-kernel@vger.kernel.org
Subject: [-mm patch] lockdep: unbalance at generic_sync_sb_inodes
Date: Fri, 5 Jan 2007 09:44:55 +0000 [thread overview]
Message-ID: <20070105094455.GC17863@slug> (raw)
In-Reply-To: <20070104220200.ae4e9a46.akpm@osdl.org>
On Thu, Jan 04, 2007 at 10:02:00PM -0800, Andrew Morton wrote:
> ftp://ftp.kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.20-rc3/2.6.20-rc3-mm1/
Hi,
The reiser4-sb_sync_inodes.patch, which goal is to:
"This patch moves spin_lock/spin_unlock down to sync_sb_inodes."
Only really moved the spin_unlock, thus triggering the following
lockdep message:
[ 65.267402] =====================================
[ 65.267508] [ BUG: bad unlock balance detected! ]
[ 65.267563] -------------------------------------
[ 65.267619] swapper/0 is trying to release lock (inode_lock) at:
[ 65.267751] [<c018f573>] generic_sync_sb_inodes+0xa6/0x2e8
[ 65.267853] but there are no more locks to release!
[ 65.267908]
[ 65.267909] other info that might help us debug this:
[ 65.268014] 1 lock held by swapper/0:
[ 65.268068] #0: (&type->s_umount_key){--..}, at: [<c0174c18>] alloc_super+0xe8/0x1a5
[ 65.268330]
[ 65.268330] stack backtrace:
[ 65.268433] [<c010390d>] show_trace_log_lvl+0x1a/0x30
[ 65.268528] [<c0103935>] show_trace+0x12/0x14
[ 65.268621] [<c0103a2f>] dump_stack+0x16/0x18
[ 65.268714] [<c013b2a0>] print_unlock_inbalance_bug+0xce/0xd8
[ 65.268811] [<c013b39b>] lock_release_non_nested+0x6f/0x172
[ 65.268907] [<c013b4d2>] lock_release_nested+0x34/0xdc
[ 65.269001] [<c013b5ce>] __lock_release+0x54/0x56
[ 65.269095] [<c013b809>] lock_release+0x46/0x60
[ 65.269188] [<c03e8660>] _spin_unlock+0x16/0x40
[ 65.269284] [<c018f573>] generic_sync_sb_inodes+0xa6/0x2e8
[ 65.269379] [<c018f7d5>] sync_sb_inodes+0x20/0x23
[ 65.269472] [<c018f937>] sync_inodes_sb+0x82/0x8a
[ 65.269566] [<c0174eab>] __fsync_super+0xd/0x84
[ 65.269659] [<c0174f2d>] fsync_super+0xb/0x19
[ 65.269753] [<c017558a>] do_remount_sb+0x30/0xee
[ 65.269846] [<c0175aa2>] get_sb_single+0x66/0x8b
[ 65.269940] [<c01b45c1>] sysfs_get_sb+0x1d/0x2c
[ 65.270036] [<c0175b49>] vfs_kern_mount+0x82/0xfb
[ 65.270130] [<c0175c19>] kern_mount+0x16/0x1d
[ 65.270223] [<c055ddb6>] sysfs_init+0x57/0xad
[ 65.270319] [<c055c8d2>] mnt_init+0xbf/0x13b
[ 65.270412] [<c055c555>] vfs_caches_init+0x97/0xa7
[ 65.270506] [<c0544bd4>] start_kernel+0x1ca/0x261
[ 65.270600] [<00000000>] 0x0
[ 65.270691] =======================
Regards,
Frederik
Signed-off-by: Frederik Deweerdt <frederik.deweerdt@gmail.com>
diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c
index ea054f7..7e84b93 100644
--- a/fs/fs-writeback.c
+++ b/fs/fs-writeback.c
@@ -306,6 +306,8 @@ int generic_sync_sb_inodes(struct super_
const unsigned long start = jiffies; /* livelock avoidance */
int ret = 0;
+ spin_lock(&inode_lock);
+
if (!wbc->for_kupdate || list_empty(&sb->s_io))
list_splice_init(&sb->s_dirty, &sb->s_io);
next prev parent reply other threads:[~2007-01-05 9:46 UTC|newest]
Thread overview: 43+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-01-05 6:02 2.6.20-rc3-mm1 Andrew Morton
2007-01-05 9:44 ` Frederik Deweerdt [this message]
2007-01-05 12:16 ` [-mm patch] lockdep: possible deadlock in sysfs Frederik Deweerdt
2007-01-05 12:48 ` Oliver Neukum
2007-01-05 15:13 ` Oliver Neukum
2007-01-05 16:42 ` Frederik Deweerdt
2007-01-05 16:53 ` Oliver Neukum
2007-01-05 16:23 ` 2.6.20-rc3-mm1 Mariusz Kozlowski
2007-01-05 18:45 ` 2.6.20-rc3-mm1 Tim Schmielau
2007-01-08 12:36 ` 2.6.20-rc3-mm1 Mariusz Kozlowski
2007-01-05 20:55 ` 2.6.20-rc3-mm1 Benjamin Herrenschmidt
2007-01-05 21:15 ` 2.6.20-rc3-mm1 Andrew Morton
2007-01-05 21:24 ` 2.6.20-rc3-mm1 Benjamin Herrenschmidt
2007-01-08 19:32 ` 2.6.20-rc3-mm1 Cornelia Huck
2007-01-08 21:19 ` 2.6.20-rc3-mm1 Benjamin Herrenschmidt
2007-01-06 1:07 ` [-mm patch] make proc_dointvec_taint() static Adrian Bunk
2007-01-06 10:58 ` 2.6.20-rc3-mm1: umount reiser4 FS stuck in D state Laurent Riffard
2007-01-06 14:12 ` Laurent Riffard
2007-01-06 16:37 ` Jens Axboe
2007-01-06 18:58 ` Vladimir V. Saveliev
2007-01-12 22:56 ` Laurent Riffard
2007-01-23 16:40 ` Vladimir V. Saveliev
2007-01-23 15:46 ` Jens Axboe
2007-01-23 18:21 ` Laurent Riffard
2007-02-01 20:04 ` Edward Shishkin
2007-02-01 20:42 ` Laurent Riffard
2007-02-01 21:52 ` Edward Shishkin
2007-02-02 21:13 ` Laurent Riffard
2007-01-06 12:55 ` 2.6.20-rc3-mm1 - git-block.patch causes hard lockups Valdis.Kletnieks
2007-01-08 8:55 ` Jens Axboe
2007-01-09 18:03 ` Valdis.Kletnieks
2007-01-06 13:44 ` 2.6.20-rc3-mm1 - rewrite-lock-in-cpufreq-to-eliminate-cpufreq-hotplug-related-issues.patch Valdis.Kletnieks
2007-01-06 16:59 ` Mattia Dongili
2007-01-07 0:29 ` Valdis.Kletnieks
2007-01-06 15:20 ` 2.6.20-rc3-mm1 - reiser4-sb_sync_inodes.patch causes boot hang Valdis.Kletnieks
2007-01-06 19:14 ` Andrew Morton
2007-01-07 0:28 ` Valdis.Kletnieks
2007-01-09 14:40 ` [Re: 2.6.20-rc3-mm1] BUG: at kernel/sched.c:3415 sub_preempt_count() Maciej Rutecki
2007-01-09 15:28 ` Frederik Deweerdt
2007-01-09 20:50 ` Maciej Rutecki
2007-01-09 21:06 ` Frederik Deweerdt
2007-01-10 16:54 ` Maciej Rutecki
2007-01-11 18:28 ` [-mm patch] remove tcp header from tcp_v4_check Frederik Deweerdt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070105094455.GC17863@slug \
--to=deweerdt@free.fr \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox