From: Craig Tierney <ctierney@hpti.com>
To: axp-list@redhat.com
Subject: Re: Problems with stuck spinlocks in 2.2.19
Date: Tue, 19 Jun 2001 17:07:16 -0600 [thread overview]
Message-ID: <20010619170716.C1597@hpti.com> (raw)
In-Reply-To: <20010618133543.E14891@hpti.com>; from ctierney@hpti.com on Mon, Jun 18, 2001 at 01:35:43PM -0600
I added debugging to the kernel and this is what I found
from the last crash:
sched.c:28 spinlock stuck in init at fffffc000032de14(0) owner slocate at fffffc
00003591ec(1) stat.c:41
Then I did:
gdb /boot/vmlinux-2.2.19-smp-debug /proc/kcore
The first pointer (0xfffffc000032de14) is:
0xfffffc000032de14 is in schedule (/usr/src/linux-2.2.19/include/asm/smplock.h:2
8).
23 * Re-acquire the kernel lock
24 */
25 static __inline__ void reacquire_kernel_lock(struct task_struct *task)
26 {
27 if (task->lock_depth >= 0)
28 spin_lock(&kernel_flag);
29 }
30
31 /*
32 * Getting the big kernel lock.
The second point (0xfffffc00003591ec) is:
0xfffffc00003591ec is in sys_newlstat (/usr/src/linux-2.2.19/include/asm/smplock
.h:40).
35 * so we only need to worry about other
36 * CPU's.
37 */
38 static __inline__ void lock_kernel(void)
39 {
40 if (!++current->lock_depth)
41 spin_lock(&kernel_flag);
42 }
43
44 static __inline__ void unlock_kernel(void)
So sys_newlstat takes us back into the filesystem fs/stat.c.
The function has a big kernel lock and unlock.
So sys_newlstat is trying to lock_kernel(). However,
the scheduler feels like trying to reacquire_kernel_lock.
I am assuming right now that the pointer to current and task
are the same (maybe) at the time of the crash.
Question: is the thread of execution in sys_newlstat getting
stuck, therefore never releasing the kernel lock and sched.c
just happens to be the other thread complaining, or are they
both trying to get the kernel lock and getting stuck? I think
it is the former.
I am tracing down the sys_newlstat command to find any 'real'
function that could be doing work and getting hung up for some
reason.
Craig
prev parent reply other threads:[~2001-06-19 23:04 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-06-18 18:08 Problems with stuck spinlocks in 2.2.19 Craig Tierney
2001-06-18 18:25 ` Peter Rival
2001-06-18 19:11 ` Greg Lindahl
2001-06-18 19:35 ` Craig Tierney
2001-06-18 20:05 ` Peter Rival
2001-06-19 23:07 ` Craig Tierney [this message]
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox