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>

git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@10304 a0bf4364-ded3-4de4-8d8a-66a801d63aff
This commit is contained in:
Shaun Ruffell 2011-11-02 19:46:18 +00:00
parent 74d86c535d
commit f0c61c85b8

View File

@ -3741,10 +3741,11 @@ static void __dahdi_find_master_span(void)
spin_lock_irqsave(&chan_lock, flags);
old_master = master;
list_for_each_entry(s, &span_list, spans_node) {
if (s->alarms)
if (s->alarms && old_master)
continue;
if (dahdi_is_digital_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;