tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

ddb(4) and LOCKDEBUG incompatibility



I hit the magic keys on a NetBSD router to break into ddb, and I got
the LOCKDEBUG panic and page fault loop (see below).  I'm wondering if
there is a prayer of using ddb and LOCKDEBUG together, since it can be
awfully useful.

It seems that we can sometimes punt on synchronization when ddb is active,
since that implies that the other CPUs on the system are suspended.
Thoughts?

Dave

***

# Stopped in pid 2733.1 (awk) at  netbsd:breakpoint+0x4:  popl    %ebp
ds          0x10
es          0x10
fs          0x30
gs          0x10
edi         0xcc
esi         0xc06fd038
ebp         0xc6271e4c
ebx         0x61
edx         0x1f
ecx         0xfe1f
eax         0x1
eip         0xc0301dbc  breakpoint+0x4
cs          0x8
eflags      0x202
esp         0xc6271e4c
ss          0x10
netbsd:breakpoint+0x4:  popl    %ebp
breakpoint(c03efe40,c03efe40,c06fd10c,0,c077b0c0,c077c000,800,0,7,8) at netbsd:b
reakpoint+0x4
comintr(c06fd000,c6271e8c,7,c0260010,c5840030,c03e0010,10,7,0,c6271eec) at netbs
d:comintr+0x583
Xintr_legacy4() at netbsd:Xintr_legacy4+0xbb
--- interrupt ---
Reader / writer lock error: rw_vector_enter: assertion failed: !cpu_intr_p()

lock address : 0x00000000c6dcc6ec type     :     sleep/adaptive
shared holds :                  0 exclusive:                  0
shares wanted:                  0 exclusive:                  0
current cpu  :                  0 last held:              65535
current lwp  : 0x00000000c6e8a3a0 last held: 000000000000000000
last locked  : 0x00000000c0225aec unlocked : 0x00000000c021ee6c
initialized  : 0x00000000c02243eb
owner/count  : 000000000000000000 flags    : 0x0000000000000008

Turnstile chain at 0xc03ff500.
=> No active turnstile for this lock.

panic: LOCKDEBUG
Stopped in pid 2733.1 (awk) at  netbsd:breakpoint+0x4:  popl    %ebp
ds          0x10
es          0x10
fs          0x30
gs          0x10
edi         0xc0366351  __func__.6673
esi         0xc03a559f  copyright+0x1bcbf
ebp         0xc627183c
ebx         0x100
edx         0xc03c0974  kprintf_slock
ecx         0xc03a559f  copyright+0x1bcbf
eax         0x1
eip         0xc0301dbc  breakpoint+0x4
cs          0x8
eflags      0x246
esp         0xc627183c
ss          0x10
netbsd:breakpoint+0x4:  popl    %ebp
breakpoint(aa55aa55,aa55aa55,aa55aa55,c6271868,c6f081a0,c03a2a03,c627188c,c027f6
5d,c03a559f,c03a2a03) at netbsd:breakpoint+0x4
panic(c03a559f,c03a2a03,c0366351,c03a2930,c03a2930,1366351,8,c6dcc6e8,c6e8a3a0,c
6dcc6ec) at netbsd:panic+0x18e
lockdebug_abort1(c03a2930,1,c0366351,c03a2930,c01cd658,c6dcc6e8,c62718ec,c02634f
3,8,3) at netbsd:lockdebug_abort1+0xad
rw_abort(8,3,3f8,c6271900,c01cd658,c6e8a3a0,3f8,0,8,3) at netbsd:rw_abort+0x2d
rw_vector_enter(c6dcc6ec,0,62,c6271920,c01cd748,c6dcc6e8,c6271a1c,c021e9ed,c6dcc
6e8,0) at netbsd:rw_vector_enter+0x223
vm_map_lock_read(c6dcc6e8,0,3f8,0,8,3,3f8,c6001970,c01cd658,0) at netbsd:vm_map_
lock_read+0x1e
uvm_fault_internal(c6dcc6e8,0,1,0,12,c6271a6c,c0239a70,c6e3d1b4,c6ec4da0,c6271aa
c) at netbsd:uvm_fault_internal+0xad
trap() at netbsd:trap+0x616
--- trap (number 6) ---
db_stack_trace_print(c0301dbc,0,fffd,c6271bf8,c02867d0,c6271cb8,c6271bc0,c01990f
0,c03fade0,c6271bd0) at netbsd:db_stack_trace_print+0x361
db_stack_trace_cmd(c0301dbc,0,ffffffff,c6271bf8,c03a559d,c0301dbd,c03bc348,c0286
7ee,c03a559d,ffffffff) at netbsd:db_stack_trace_cmd+0x54
db_command(c03bc2af,c03bc2b1,c6271cc0,c01981e2,0,c6271d1c,c6271cc0,c01986cd,c030
1dbc,0) at netbsd:db_command+0xfc
db_command_loop(c0301dbc,aad,1,c6e3d31d,800,1,c034dc88,ffffff,8,c6271e0c) at net
bsd:db_command_loop+0x7d
db_trap(1,0,58,c03036cf,c07839a4,c6271d1c,0,c61bbef4,0,10) at netbsd:db_trap+0xf
e
kdb_trap(1,0,c6271e0c,c6e3d1b4,c06fd10c,c6271dcc,c034dc88,c6e3d1b4,c6ec4da0,c627
1e9c) at netbsd:kdb_trap+0x148
trap() at netbsd:trap+0x25d
--- trap (number 1) ---
breakpoint(c03efe40,c03efe40,c06fd10c,0,c077b0c0,c077c000,800,0,7,8) at netbsd:b
reakpoint+0x4
comintr(c06fd000,c6271e8c,7,c0260010,c5840030,c03e0010,10,7,0,c6271eec) at netbs
d:comintr+0x583
Xintr_legacy4() at netbsd:Xintr_legacy4+0xbb
--- interrupt ---
uvm_fault(0xc6dcc6e8, 0, 1) -> 0xe
kernel: supervisor trap page fault, code=0
Stopped in pid 2733.1 (awk) at  netbsd:db_stack_trace_print+0x361:      movl    0
x34(%esi),%edx
ds          0x10
es          0x10
fs          0x30
gs          0x10
edi         0xc02867d0  db_printf
esi         0xb
ebp         0xc6271570
ebx         0xc6271e90
edx         0
ecx         0
eax         0xc6271e90
eip         0xc0303f81  db_stack_trace_print+0x361
cs          0x8
eflags      0x10286
esp         0
ss          0x156c
netbsd:db_stack_trace_print+0x361:      movl    0x34(%esi),%edx
db_stack_trace_print(c0301dbc,0,ffee,c62715e8,c02867d0,c62716a8,c62715b0,c01990f
0,c03fade0,c62715c0) at netbsd:db_stack_trace_print+0x361
db_stack_trace_cmd(c0301dbc,0,ffffffff,c62715e8,c03a559d,c0301dbd,c03bc348,c0286
7ee,c03a559d,ffffffff) at netbsd:db_stack_trace_cmd+0x54
db_command(c03bc2af,c03bc2b1,c62716b0,c01981e2,0,c627170c,c62716b0,c01986cd,c030
1dbc,0) at netbsd:db_command+0xfc
db_command_loop(c0301dbc,aad,1,c6e3d31d,3f8,0,8,0,8,c62717fc) at netbsd:db_comma
nd_loop+0x7d
db_trap(1,0,58,c03036cf,a,c627171c,0,8,c03edfe0,10) at netbsd:db_trap+0xfe
kdb_trap(1,0,c62717fc,c6e3d1b4,1,1,1,c6e3d1b4,c6ec4da0,c627181c) at netbsd:kdb_t
rap+0x148
trap() at netbsd:trap+0x25d
--- trap (number 1) ---
breakpoint(aa55aa55,aa55aa55,aa55aa55,c6271868,c6f081a0,c03a2a03,c627188c,c027f6
5d,c03a559f,c03a2a03) at netbsd:breakpoint+0x4
panic(c03a559f,c03a2a03,c0366351,c03a2930,c03a2930,1366351,8,c6dcc6e8,c6e8a3a0,c
6dcc6ec) at netbsd:panic+0x18e
lockdebug_abort1(c03a2930,1,c0366351,c03a2930,c01cd658,c6dcc6e8,c62718ec,c02634f
3,8,3) at netbsd:lockdebug_abort1+0xad
rw_abort(8,3,3f8,c6271900,c01cd658,c6e8a3a0,3f8,0,8,3) at netbsd:rw_abort+0x2d

-- 
David Young             OJC Technologies
dyoung%ojctech.com@localhost      Urbana, IL * (217) 278-3933 ext 24


Home | Main Index | Thread Index | Old Index