[Home]

Summary:DAHLIN-00109: dahdi_dynamic_loc crashes as soon as a valid span pair is activated
Reporter:Marcelo APacheco (mapacheco)Labels:
Date Opened:2009-05-27 22:27:50Date Closed:2009-06-26 12:22:47
Priority:CriticalRegression?No
Status:Closed/CompleteComponents:dahdi_dynamic_loc
Versions:2.1.0.4 Frequency of
Occurrence
Related
Issues:
Environment:Attachments:
Description:Sample /etc/dahdi/system.conf:
dynamic=loc,1:0,24,0
dynamic=loc,1:1,24,0
bchan=1-23
dchan=24
bchan=25-47
dchan=48
mulaw=1-23,25-47
loadzone=us
defaultzone=us

modprobe dahdi_dummy
dahdi_cfg -v

My two systems get into a hard freeze (not even Alt-SysRq works), I already debugged and found the root of the issue, see below.

If I comment all spinlock statements on dahdi_dynamic.c function dahdi_dynamic_receive, then it doesn't freeze. The underlying cause for the freeze we're having a recursive spinlock request, ztd_sendmessage calls ztdlocal_transmit which calls dahdi_dynamic_receive with dlock spinlock held.
Comments:By: Tzafrir Cohen (tzafrir) 2009-06-06 14:58:31

any chance you could get the trace? e.g. get a screen shot of it?

Is it legal for a local dynamic span not to point to a real span?

By: Marcelo Pacheco (macpacheco) 2009-06-06 15:21:40

Dear tzafrir.
I think you didn't compreehend the report, HARD FREEZE (NOT EVEN Alt-SysRq works). So there's no stack trace to be obtained. However I'm explaining what the issue is, with an extremely dirty hack that avoids the issue, so I know what the issue is, I just haven't engineered a solid solution.
You can reproduce the issue in 5 mins, all you need is dahdi-linux and dahdi-tools compiled and installed, not even Asterisk is required.

By: Digium Subversion (svnbot) 2009-06-26 12:22:46

Repository: dahdi
Revision: 6771

U   linux/trunk/drivers/dahdi/dahdi_dynamic.c

------------------------------------------------------------------------
r6771 | sruffell | 2009-06-26 12:22:45 -0500 (Fri, 26 Jun 2009) | 6 lines

dahdi_dynamic: Release the dlock before calling accross modules.

Resolves a hard lock due to a recursive spinlock grab at startup.

Reported by: mapacheco
(closes issue DAHLIN-109)
------------------------------------------------------------------------

http://svn.digium.com/view/dahdi?view=rev&revision=6771