dahdi: First span registered becomes master by default.

r10205 "dahdi: Check for master in DAHDI_STARTUP / resolves MeetMe
regression." did not handle the case for the wcb4xxp driver since it
would set DAHDI_FLAG_RUNNING as part of the probe. Therefore, the
DAHDI_STARTUP ioctl was never processed for it, creating a situation
where audio is missing on channels that are conferenced with channels on
the BRI spans.

Signed-off-by: Shaun Ruffell <sruffell@digium.com>

Origin: http://svnview.digium.com/svn/dahdi?view=rev&rev=10304

git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/branches/2.5@10305 a0bf4364-ded3-4de4-8d8a-66a801d63aff
This commit is contained in:
Shaun Ruffell
2011-11-02 20:01:58 +00:00
parent 40942e2a43
commit d624adb358

View File

@@ -3683,10 +3683,11 @@ static void __dahdi_find_master_span(void)
spin_lock_irqsave(&chan_lock, flags);
old_master = master;
list_for_each_entry(s, &span_list, node) {
if (s->alarms)
if (s->alarms && old_master)
continue;
if (!is_analog_span(s) &&
!test_bit(DAHDI_FLAGBIT_RUNNING, &s->flags))
!test_bit(DAHDI_FLAGBIT_RUNNING, &s->flags) &&
old_master)
continue;
if (!can_provide_timing(s))
continue;