From mboxrd@z Thu Jan 1 00:00:00 1970 From: Edward Shishkin Subject: Re: Reiser4: possible circular locking dependency detected Date: Tue, 24 Feb 2009 12:23:06 +0300 Message-ID: <49A3BC7A.3050804@gmail.com> References: <499ABE6C.6010904@free.fr> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <499ABE6C.6010904@free.fr> Sender: reiserfs-devel-owner@vger.kernel.org List-ID: Content-Type: text/plain; charset="us-ascii" To: Laurent Riffard Cc: ReiserFS Mailing List Laurent Riffard wrote: > Hello, > > Hi Laurent > I've got this warning in my logs with 2.6.29-rc5 + reiser4 patches: > > ======================================================= > [ INFO: possible circular locking dependency detected ] > 2.6.29-rc5-00012-g94aca52 #132 > ------------------------------------------------------- > git/5217 is trying to acquire lock: > (&data->latch){----}, at: [] get_exclusive_access+0x12/0x1c [reiser4] > > but task is already holding lock: > (&mm->mmap_sem){----}, at: [] sys_mmap2+0x44/0x7b > > which lock already depends on the new lock. > > > the existing dependency chain (in reverse order) is: > > -> #1 (&mm->mmap_sem){----}: > [] __lock_acquire+0x98d/0xb00 > [] lock_acquire+0x5b/0x81 > [] might_fault+0x68/0x88 > This is a false positive provided by might_fault(), introduced in the latest kernels. User page has to be brought in so that major page fault does not occur here when the non-exclusive access is acquired (by read_unix_file). We need to teach the code somehow to not produce this false alarm. I'll take a look.. Thanks, Edward. > [] reiser4_read_tail+0x60/0xc2 [reiser4] > [] read_unix_file+0x2da/0x3a0 [reiser4] > [] reiser4_read_careful+0xac/0xf4 [reiser4] > [] vfs_read+0x79/0xaa > [] sys_read+0x3b/0x60 > [] sysenter_do_call+0x12/0x43 > [] 0xffffffff > > -> #0 (&data->latch){----}: > [] __lock_acquire+0x862/0xb00 > [] lock_acquire+0x5b/0x81 > [] down_write+0x2a/0x46 > [] get_exclusive_access+0x12/0x1c [reiser4] > [] get_exclusive_access_careful+0x10/0x32 [reiser4] > [] mmap_unix_file+0x48/0x10a [reiser4] > [] reiser4_mmap_careful+0xa1/0xe6 [reiser4] > [] mmap_region+0x219/0x3b0 > [] do_mmap_pgoff+0x1e4/0x230 > [] sys_mmap2+0x5a/0x7b > [] sysenter_do_call+0x12/0x43 > [] 0xffffffff > > other info that might help us debug this: > > 1 lock held by git/5217: > #0: (&mm->mmap_sem){----}, at: [] sys_mmap2+0x44/0x7b > > stack backtrace: > Pid: 5217, comm: git Not tainted 2.6.29-rc5-00012-g94aca52 #132 > Call Trace: > [] ? printk+0xf/0x17 > [] print_circular_bug_tail+0x5d/0x68 > [] __lock_acquire+0x862/0xb00 > [] ? static_obj+0x6d/0x79 > [] lock_acquire+0x5b/0x81 > [] ? get_exclusive_access+0x12/0x1c [reiser4] > [] down_write+0x2a/0x46 > [] ? get_exclusive_access+0x12/0x1c [reiser4] > [] get_exclusive_access+0x12/0x1c [reiser4] > [] get_exclusive_access_careful+0x10/0x32 [reiser4] > [] mmap_unix_file+0x48/0x10a [reiser4] > [] reiser4_mmap_careful+0xa1/0xe6 [reiser4] > [] mmap_region+0x219/0x3b0 > [] do_mmap_pgoff+0x1e4/0x230 > [] sys_mmap2+0x5a/0x7b > [] sysenter_do_call+0x12/0x43 > > > The set of reiser4 patches I'm using is available from http://laurent.riffard.free.fr/reiser4/reiser4-for-2.6.29-rc5/: > 0001-Reiser4-for-Linux-2.6.28.patch > 0002-reiser4-adjust-to-the-new-aops-fixup.patch > 0003-Reiser4-fix-BUG-using-smp_processor_id-in-preemp.patch > 0004-Reiser4-Change-current-fs-ug-id-to-current_fs-ug-i.patch > 0005-Reiser4-fix-__grab_cache_page-usage.patch > 0006-Revert-Reiser4-fix-__grab_cache_page-usage.patch > 0007-Reiser4-build-fix.patch > 0008-reiser4-update-names-of-quota-methods.patch > > ~~ > laurent > > > -- > To unsubscribe from this list: send the line "unsubscribe reiserfs-devel" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > >