Commit Graph

83 Commits

Author SHA1 Message Date
Alexander Traud cc025026b7 progdocs: Fix for Doxygen, the hidden parts.
ASTERISK-29779

Change-Id: If338163488498f65fa7248b60e80299c0a928e4b
2021-12-02 10:37:38 -06:00
Josh Soref d46ba42910 channels: Spelling fixes
Correct typos of the following word families:

appease
permanently
overriding
residue
silliness
extension
channels
globally
reference
japanese
group
coordinate
registry
information
inconvenience
attempts
cadence
payloads
presence
provisioning
mimics
behavior
width
natively
syslabel
not owning
unquelch
mostly
constants
interesting
active
unequipped
brodmann
commanding
backlogged
without
bitstream
firmware
maintain
exclusive
practically
structs
appearance
range
retransmission
indication
provisional
associating
always
whether
cyrillic
distinctive
components
reinitialized
initialized
capability
switches
occurring
happened
outbound

ASTERISK-29714

Change-Id: Ife52ee89cd2170b684fa651ca72b1cb911a57339
2021-11-16 05:35:29 -06:00
Kevin Harwell 9637e1dfdc MWI: Update modules that subscribe to MWI to use new API calls
The MWI core recently got some new API calls that make tracking MWI state
lifetime more reliable. This patch updates those modules that subscribe to
specific MWI topics to use the new API. Specifically, these modules now
subscribe to both MWI topics and MWI state.

ASTERISK-28442

Change-Id: I32bef880b647246823dbccdf44a98d384fcabfbd
2019-07-08 18:12:49 -05:00
George Joseph 4275ca16a1 build: A few gcc 7 error fixes
Change-Id: I7b5300fbf1af7d88d47129db13ad6dbdc9b553ec
2017-09-25 07:32:14 -05:00
Patric Marschall 7908ae4934 sig_pri.h: force_restart_unavailable_chans in wrong scope
In channels/sig_pri.h, struct sig_pri_span, the field
force_restart_unavailable_chans is only defined if

#if defined(HAVE_PRI_MCID) is true.

All other occurences of force_restart_unavailable_chans are outside of the

#if defined(HAVE_PRI_MCID)
endif

scope.

ASTERISK-25257 #close
Reported by: Patric Marschall

Change-Id: I071de89cc2cd0d85927a013036e235851f672549
2015-07-17 11:02:24 -05:00
Richard Mudgett 03c51cf525 chan_dahdi: Add the chan_dahdi.conf force_restart_unavailable_chans option.
Some telco switches occasionally ignore ISDN RESTART requests.  The fix
for ASTERISK-19608 added an escape clause for B channels in the restarting
state if the telco ignores a RESTART request.  If the telco fails to
acknowledge the RESTART then Asterisk will assume the telco acknowledged
the RESTART on the second call attempt requesting the B channel by the
telco.  The escape clause is good for dealing with RESTART requests in
general but it does cause the next call for the restarting B channel to be
rejected if the telco insists the call must go on that B channel.

chan_dahdi doesn't really need to issue a RESTART request in response to
receiving a cause 44 (Requested channel not available) code.  Sending the
RESTART in such a situation is not required (nor prohibited) by the
standards.  I think chan_dahdi does this for historical reasons to deal
with buggy peers to get channels unstuck in a similar fashion as the
chan_dahdi.conf resetinterval option.

* Add the chan_dahdi.conf force_restart_unavailable_chans compatability
option that when disabled will prevent chan_dahdi from trying to RESTART
the channel in response to a cause 44 code.

ASTERISK-25034 #close
Reported by: Richard Mudgett

Change-Id: Ib8b17a438799920f4a2038826ff99a1884042f65
2015-04-30 10:24:57 -05:00
Richard Mudgett 3bd495a688 chan_dahdi: Add inband_on_setup_ack compatibility option.
The new inband_on_setup_ack option causes Asterisk to assume inband audio
may be present when a SETUP_ACKNOWLEDGE message is received.

Q.931 Section 5.1.3 says that in scenarios with overlap dialing, when a
dialtone is sent from the network side, progress indicator 8 "Inband info
now available" MAY be sent to the CPE if no digits were received with the
SETUP.  It is thus implied that the ie is mandatory if digits came with
the SETUP and dialtone is needed.  This option should be enabled, when the
network sends dialtone and you want to hear it, but the network doesn't
send the progress indicator when needed.

NOTE: For Q.SIG setups this option should be enabled when outgoing overlap
dialing is also enabled because Q.SIG does not send the progress indicator
with the SETUP ACK.

The commit -r413714 (AST-1338) which causes this issue was dealing with a
SIP-to-ISDN interoperability issue.

This commit is a merge of the two patches indicated below.

ASTERISK-23897 #close
Reported by: Pavel Troller
Patches:
      pri-4.diff (license #6302) patch uploaded by Pavel Troller
      jira_asterisk_23897_v11.patch (license #5621) patch uploaded by rmudgett

Review: https://reviewboard.asterisk.org/r/3633/
........

Merged revisions 417956 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 417957 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 417958 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@417976 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-07-03 22:22:36 +00:00
Tzafrir Cohen 3451d6a72d suspended destructions of pri spans on events
If a DAHDI span disappears, we wish for its representation in Asterisk
to be destroyed as well.

The information about the span's removal may come from several paths:

1. DAHDI sends DAHDI_EVENT_REMOVE on every channel.
2. An extra DAHDI_EVENT_REMOVED is sent on every subsequent call to
   DAHDI_GET_EVENT.
3. Every read (including the internal one by libpri on the D-channel)
   returns -ENODEV.

Asterisk responsds to DAHDI_EVENT_REMOVE on a channel by destroying it.

Destroying a channel requires holding the channel list lock (iflock).
Destroying a channel that is part of a span requires holding the span's
lock. Destroying a channel from a context that holds the span lock,
while at the same time another channel is destroyed directly, leads to a
deadlock. Solution: don't destroy span while holding the channels list
lock.

Thus changes in this patch:
* Deferring removal of PRI spans in response to events: doomed spans
  are collected on a list.
* Doomed spans are removed periodically by the monitor thread.
* ENODEV reads from the D-channel will warant the same deferred removal.

Review: https://reviewboard.asterisk.org/r/3548/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@417059 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-06-23 07:44:19 +00:00
Richard Mudgett ecbd052741 uniqueid: Fix chan_dahdi, sig_pri, sig_ss7, test_cdr, and test_cel compiler errors.
(issue ASTERISK-23120)
........

Merged revisions 410171 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@410174 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-03-07 19:19:04 +00:00
Richard Mudgett e4803bbd9e Voicemail: Remove mailbox identifier format (box@context) assumptions in the system.
This change is in preparation for external MWI support.

Removed code from the system for normal mailbox handling that appends
@default to the mailbox identifier if it does not have a context.  The
only exception is the legacy hasvoicemail users.conf option.  The legacy
option will only work for app_voicemail mailboxes.  The system cannot make
any assumptions about the format of the mailbox identifer used by
app_voicemail.

chan_sip and chan_dahdi/sig_pri had the most changes because they both
tried to interpret the mailbox identifier.  chan_sip just stored and
compared the two components.  chan_dahdi actually used the box
information.

The ISDN MWI support configuration options had to be reworked because
chan_dahdi was parsing the box@context format to get the box number.  As a
result the mwi_vm_boxes chan_dahdi.conf option was added and is documented
in the chan_dahdi.conf.sample file.

Review: https://reviewboard.asterisk.org/r/3072/
........

Merged revisions 404348 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404350 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-19 16:52:43 +00:00
Kinsey Moore 59753b1ea1 Strip down the old event system
This removes unused code, event types, IE pltypes, and event IE types
where possible and makes several functions private that were once
public. This includes a renumbering of the remaining event and IE types
which breaks binary compatibility with previous versions. The last
remaining consumers of the old event system (or parts thereof) are
main/security_events.c, res/res_security_log.c, tests/test_cel.c,
tests/test_event.c, main/cel.c, and the CEL backends.

Review: https://reviewboard.asterisk.org/r/2703/
(closes issue ASTERISK-22139)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@396887 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-08-17 14:39:27 +00:00
Richard Mudgett 6114166237 Refactor chan_dahdi/sig_analog/sig_pri and chan_misdn to use the common transfer functions.
(closes issue ASTERISK-21523)
Reported by: Matt Jordan

(closes issue ASTERISK-21524)
Reported by: Matt Jordan

Review: https://reviewboard.asterisk.org/r/2600/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390804 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-07 01:06:49 +00:00
Richard Mudgett 79818112fd chan_dahdi: Add inband_on_proceeding compatibility option.
The new inband_on_proceeding option causes Asterisk to assume inband audio
may be present when a PROCEEDING message is received.

Q.931 Section 5.1.2 says the network cannot assume that the CPE side has
attached to the B channel at this time without explicitly sending the
progress indicator ie informing the CPE side to attach to the B channel
for audio.  However, some non-compliant ISDN switches send a PROCEEDING
without the progress indicator ie indicating inband audio is available and
assume that the CPE device has connected the media path for listening to
ringback and other messages.

ASTERISK-17834 which causes this issue was dealing with a non-compliant
network switch.

(closes issue ASTERISK-21151)
Reported by: Gianluca Merlo
Tested by: rmudgett
........

Merged revisions 384685 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 384689 from http://svn.asterisk.org/svn/asterisk/branches/11


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@384696 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-04-03 20:20:09 +00:00
Kinsey Moore 99aa02d17f Transition MWI to Stasis-core
Remove MWI's dependency on the event system by moving it to
Stasis-core. This also introduces forwarding topic pools in Stasis-core
which aggregate many dynamically allocated topics into a single primary
topic.

Review: https://reviewboard.asterisk.org/r/2368/
(closes issue ASTERISK-21097)
Patch-by: Kinsey Moore


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@383284 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-03-16 15:45:58 +00:00
Matthew Jordan 8018b879a2 Clean up doxygen warnings
This patch fixes numerous doxygen warnings across Asterisk.  It also updates
the makefile to regenerate the doxygen configuration on the local system
before running doxygen to help prevent warnings/errors on the local system.

Much thanks to Andrew for tackling one of the Asterisk janitor projects!

(issue ASTERISK-20259)
Reported by: Andrew Latham
Patches:
  doxygen_partial.diff uploaded by Andrew Latham (license 5985)
  make_progdocs.diff uploaded by Andrew Latham (license 5985)



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@371989 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-08-30 14:23:28 +00:00
Richard Mudgett 35bf5efeaf Convert sig_pri to use a global callback table.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@370893 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-08-08 00:35:37 +00:00
Richard Mudgett d2ac624b87 Clear ISDN channel resetting state if the peer continues to use it.
Some ISDN switches occasionally fail to send a RESTART ACKNOWLEDGE in
response to a RESTART request.

* Made the second SETUP received after sending a RESTART request clear the
channel resetting state as if the peer had sent the expected RESTART
ACKNOWLEDGE before continuing to process the SETUP.  The peer may not be
sending the expected RESTART ACKNOWLEDGE.

(issue ASTERISK-19608)
(issue AST-844)
(issue AST-815)
Patches:
      jira_ast_815_v1.8.patch (license #5621) patch uploaded by rmudgett (modified)
........

Merged revisions 363687 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 363688 from http://svn.asterisk.org/svn/asterisk/branches/10


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@363689 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-04-25 19:55:12 +00:00
Richard Mudgett c7cb03a975 Add ability to ignore layer 1 alarms for BRI PTMP lines.
Several telcos bring the BRI PTMP layer 1 down when the line is idle.
When layer 1 goes down, Asterisk cannot make outgoing calls.  Incoming
calls could fail as well because the alarm processing is handled by a
different code path than the Q.931 messages.

* Add the layer1_presence configuration option to ignore layer 1 alarms
when the telco brings layer 1 down.  This option can be configured by span
while the similar DAHDI driver teignorered=1 option is system wide.  This
option unlike layer2_persistence does not require libpri v1.4.13 or newer.

Related to JIRA AST-598

JIRA ABE-2845
........

Merged revisions 362428 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 362429 from http://svn.asterisk.org/svn/asterisk/branches/10


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@362430 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-04-18 16:41:17 +00:00
Richard Mudgett a22b56235b Add ability for chan_dahdi ISDN to block connected line updates per span.
Added new chan_dahdi.conf colp_send option parameter to block connected
line updates per span.

(closes issue ASTERISK-17025)
Reported by: Michael Smith


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@358997 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-03-13 21:18:31 +00:00
Alec L Davis a4f6d96b2e push 'outgoing' flag from sig_XXX up to chan_dahdi
'p->outgoing' in chan_dahdi and sig_analog wern't kept in sync, particulary FXS ast_hangup didn't clear the 'outgoing' flag.
sig_pri and sig_ss7 were keeping 'outgoing' flag insync.

Now provides a callback for all the low level sig_XXX modules.

(issue ASTERISK-19316)

alecdavis (license 585)
Reported by: Jeremy Pepper
Tested by: alecdavis
 
Review: https://reviewboard.asterisk.org/r/1747/
........

Merged revisions 355850 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 355851 from http://svn.asterisk.org/svn/asterisk/branches/10


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@355852 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-18 08:02:08 +00:00
Richard Mudgett a4f5d2c2ef Restore alternate SIG_PRI_DEBUG_DEFAULT meaning.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@354174 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-06 20:56:23 +00:00
Kinsey Moore 49ed50d8ac Allow more control over the output of pri debug
This changes the debuglevel of 'pri set debug' to a bit mask allowing the user
to independently select bits of output:
1 libpri internals including state machine
2 Decoded Q.931 messages
4 Decoded Q.921 headers
8 raw hex dump of the full frames

Additionally, this ensures that the meaning of "on" does not change and
intrudces intense and hex to simplify usage.

(closes issue ASTERISK-17159)
Original-patch-by: wimpy


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@354165 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-06 20:18:16 +00:00
Richard Mudgett 63c5eaee43 Restore the 'w' modifier support for ISDN spans. Dial(DAHDI/g0/1234w888)
This feature also causes the sending complete ie to be sent for switch
types that do not automatically send the ie.  (EuroISDN/ETSI)

The main difference between dialing Dial(DAHDI/g0/1234w888) and
Dial(DAHDI/g0/1234,,D(888)) is the sending of the sending complete ie.

(closes issue ASTERISK-19176)
Reported by: rmudgett
Tested by: rmudgett
........

Merged revisions 353867 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 353868 from http://svn.asterisk.org/svn/asterisk/branches/10


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@353872 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-02 20:18:11 +00:00
Richard Mudgett 23bc964e1c Constify some more channel driver technology callback parameters.
Review: https://reviewboard.asterisk.org/r/1707/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@353685 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-01 19:53:38 +00:00
Richard Mudgett 265102faf8 Merged revisions 332265 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/10

................
  r332265 | rmudgett | 2011-08-17 11:01:29 -0500 (Wed, 17 Aug 2011) | 33 lines
  
  Merged revisions 332264 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.8
  
  ........
    r332264 | rmudgett | 2011-08-17 10:51:08 -0500 (Wed, 17 Aug 2011) | 26 lines
    
    Outgoing BRI calls fail when using Asterisk 1.8 with HA8, HB8, and B410P cards.
    
    France Telecom brings layer 2 and layer 1 down on BRI lines when the line
    is idle.  When layer 1 goes down Asterisk cannot make outgoing calls and
    the HA8 and HB8 cards also get IRQ misses.
    
    The inability to make outgoing calls is because the line is in red alarm
    and Asterisk will not make calls over a line it considers unavailable.
    The IRQ misses for the HA8 and HB8 card are because the hardware is
    switching clock sources from the line which just brought layer 1 down to
    internal timing.
    
    There is a DAHDI option for the B410P card to not tell Asterisk that layer
    1 went down so Asterisk will allow outgoing calls: "modprobe wcb4xxp
    teignored=1".  There is a similar DAHDI option for the HA8 and HB8 cards:
    "modprobe wctdm24xxp bri_teignored=1".  Unfortunately that will not clear
    up the IRQ misses when the telco brings layer 1 down.
    
    * Add layer 2 persistence option to customize the layer 2 behavior on BRI
    PTMP lines.  The new option has three settings: 1) Use libpri default
    layer 2 setting.  2) Keep layer 2 up.  Bring layer 2 back up when the peer
    brings it down.  3) Leave layer 2 down when the peer brings it down.
    Layer 2 will be brought up as needed for outgoing calls.
    
    JIRA AST-598
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@332270 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-08-17 16:18:27 +00:00
Richard Mudgett 5257a915a8 Option needed for Q931_IE_TIME_DATE to be optional in CONNECT message.
The NEC SV8300 rejects the Q931_IE_TIME_DATE for Q.SIG.

Add option to specify if and how much of the current time is put in
Q931_IE_TIME_DATE.
* Send date/time ie never.
* Send date/time ie date only.
* Send date/time ie date and hour.
* Send date/time ie date, hour, and minute.
* Send date/time ie date, hour, minute, and second.
* Send date/time ie default: Libpri will send date and hhmm only when in
NT PTMP mode to support ISDN phones.

(closes issue #19221)
Reported by: kenner

JIRA SWP-3396


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@319427 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-05-17 20:13:27 +00:00
Richard Mudgett 0f1ff9141e Implement AMI action PRIShowSpans.
PRIShowSpans works like the AMI action DAHDIShowChannels but for PRI
spans.  It is similar to the CLI command "pri show spans".

(closes issue #15980)
Reported by: dwery


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@314735 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-04-21 22:53:05 +00:00
Richard Mudgett 37274c73ee Problems with ISDN MWI to phones.
The "controlling user number" is always the number of the voice mail box
which is identical with the subscriber number itself.  This number which
is listed in the ISDN phone MWI menu cannot be called back to contact the
voice mail box.  The controlling user number should be made configurable.

JIRA ABE-2738
JIRA SWP-2846


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@314116 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-04-18 19:48:00 +00:00
Richard Mudgett ce17f956dc Add private lock deadlock avoidance callback to PRI and SS7.
Factor out the equivalent function for analog.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@313100 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-04-08 16:17:32 +00:00
Richard Mudgett 698a356737 Merged revisions 312949 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8

........
  r312949 | rmudgett | 2011-04-05 13:45:24 -0500 (Tue, 05 Apr 2011) | 6 lines
  
  Crash if ISDN span layer 1 is down on initial load.
  
  Regression from -r312575 B channel shifting during negotiation.
  
  * Also combine updating the alarm flag with clearing the resetting flag.
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@312950 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-04-05 18:47:11 +00:00
Richard Mudgett e1ceb52b51 Merged revisions 312575 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8

................
  r312575 | rmudgett | 2011-04-04 11:10:50 -0500 (Mon, 04 Apr 2011) | 52 lines
  
  Merged revisions 312574 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.6.2
  
  ................
    r312574 | rmudgett | 2011-04-04 11:00:02 -0500 (Mon, 04 Apr 2011) | 45 lines
    
    Merged revisions 312573 via svnmerge from 
    https://origsvn.digium.com/svn/asterisk/branches/1.4
    
    ........
      r312573 | rmudgett | 2011-04-04 10:49:30 -0500 (Mon, 04 Apr 2011) | 38 lines
      
      Issues with ISDN calls changing B channels during call negotiations.
      
      The handling of the PROCEEDING message was not using the correct call
      structure if the B channel was changed.  (The same for PROGRESS.) The call
      was also not hungup if the new B channel is not provisioned or is busy.
      
      * Made all call connection messages (SETUP_ACKNOWLEDGE, PROCEEDING,
      PROGRESS, ALERTING, CONNECT, CONNECT_ACKNOWLEDGE) ensure that they are
      using the correct structure and B channel.  If there is any problem with
      the operations then the call is now hungup with an appropriate cause code.
      
      * Made miscellaneous messages (INFORMATION, FACILITY, NOTIFY) find the
      correct structure by looking for the call and not using the channel ID.
      NOTIFY is an exception with versions of libpri before v1.4.11 because a
      call pointer is not available for Asterisk to use.
      
      * Made all hangup messages (DISCONNECT, RELEASE, RELEASE_COMPLETE) find
      the correct structure by looking for the call and not using the channel
      ID.
      
      (closes issue #18313)
      Reported by: destiny6628
      Tested by: rmudgett
      JIRA SWP-2620
      
      (closes issue #18231)
      Reported by: destiny6628
      Tested by: rmudgett
      JIRA SWP-2924
      
      (closes issue #18488)
      Reported by: jpokorny
      JIRA SWP-2929
      
      JIRA AST-437 (The issues fixed here are most likely causing this JIRA issue.)
      JIRA DAHDI-406
      JIRA LIBPRI-33 (Stuck resetting flag likely fixed)
    ........
  ................
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@312579 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-04-04 16:17:58 +00:00
Richard Mudgett 928ec2b990 Merged revisions 309445 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8

........
  r309445 | rmudgett | 2011-03-04 09:22:04 -0600 (Fri, 04 Mar 2011) | 46 lines
  
  Get real channel of a DAHDI call.
  
  Starting with Asterisk v1.8, the DAHDI channel name format was changed for
  ISDN calls to: DAHDI/i<span>/<number>[:<subaddress>]-<sequence-number>
  
  There were several reasons that the channel name had to change.
  
  1) Call completion requires a device state for ISDN phones.  The generic
  device state uses the channel name.
  
  2) Calls do not necessarily have B channels.  Calls placed on hold by an
  ISDN phone do not have B channels.
  
  3) The B channel a call initially requests may not be the B channel the
  call ultimately uses.  Changes to the internal implementation of the
  Asterisk master channel list caused deadlock problems for chan_dahdi if it
  needed to change the channel name.  Chan_dahdi no longer changes the
  channel name.
  
  4) DTMF attended transfers now work with ISDN phones because the channel
  name is "dialable" like the chan_sip channel names.
  
  For various reasons, some people need to know which B channel a DAHDI call
  is using.
  
  * Added CHANNEL(dahdi_span), CHANNEL(dahdi_channel), and
  CHANNEL(dahdi_type) so the dialplan can determine the B channel currently
  in use by the channel.  Use CHANNEL(no_media_path) to determine if the
  channel even has a B channel.
  
  * Added AMI event DAHDIChannel to associate a DAHDI channel with an
  Asterisk channel so AMI applications can passively determine the B channel
  currently in use.  Calls with "no-media" as the DAHDIChannel do not have
  an associated B channel.  No-media calls are either on hold or
  call-waiting.
  
  (closes issue #17683)
  Reported by: mrwho
  Tested by: rmudgett
  
  (closes issue #18603)
  Reported by: arjankroon
  Patches:
        issue17683_18603_v1.8_v2.patch uploaded by rmudgett (license 664)
  Tested by: stever28, rmudgett
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@309446 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-03-04 15:28:20 +00:00
Richard Mudgett 4a48600231 Add CLI "pri show channels" command.
List the current mapping of DAHDI B channels to Asterisk channel names and
which calls are on hold or call-waiting.  Calls on hold or call-waiting
are not associated with any B channel.

JIRA LIBPRI-27
JIRA SWP-2547


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@307964 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-02-15 21:42:55 +00:00
Richard Mudgett b2ef13cb60 Merged revisions 307879 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8

........
  r307879 | rmudgett | 2011-02-15 10:13:55 -0600 (Tue, 15 Feb 2011) | 37 lines
  
  No response sent for SIP CC subscribe/resubscribe request.
  
  Asterisk does not send a response if we try to subscribe for call
  completion after we have received a 180 Ringing.  You can only subscribe
  for call completion when the call has been cleared.
  
  When we receive the 180 Ringing, for this call, its call-completion state
  is 'CC_AVAILABLE'.  If we then send a subscribe message to Asterisk, it
  trys to change the call-completion state to 'CC_CALLER_REQUESTED'.
  Because this is an invalid state change, it just ignores the message.  The
  only state Asterisk will accept our subscribe message is in the
  'CC_CALLER_OFFERED' state.
  
  Asterisk will go into the 'CC_CALLER_OFFERED' when the SIP client clears
  the call by sending a CANCEL.
  
  Asterisk should always send a response.  Even if its a negative one.
  
  
  The fix is to allow for the CCSS core to notify a CC agent that a failure
  has occurred when CC is requested.  The "ack" callback is replaced with a
  "respond" callback.  The "respond" callback has a parameter indicating
  either a successful response or a specific type of failure that may need
  to be communicated to the requester.
  
  (closes issue #18336)
  Reported by: GeorgeKonopacki
  Tested by: mmichelson, rmudgett
  
  JIRA SWP-2633
  
  (closes issue #18337)
  Reported by: GeorgeKonopacki
  Tested by: mmichelson
  
  JIRA SWP-2634
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@307883 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-02-15 16:18:43 +00:00
Richard Mudgett 209a39f4b0 Use correct conditional for MCID send.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@306791 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-02-08 00:26:01 +00:00
Richard Mudgett 49feb747ba Pass a MCID request to the bridged channel.
Pass a MCID request to the bridged channel so the bridged channel can send
it to the network.

The ability to send the MCID request on an ISDN span is enabled with the
new chan_dahdi.conf mcid_send option.

JIRA SWP-2845
JIRA ABE-2736


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@306755 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-02-07 23:33:44 +00:00
Richard Mudgett a8aeb04a9f Add ISDN display ie text handling options to chan_dahdi.conf.
The display ie handling can be controlled independently in the send and
receive directions with the following options:

* Block display text data.

* Use display text in SETUP/CONNECT messages for name.

* Use display text for COLP name updates (FACILITY/NOTIFY as appropriate).

* Pass arbitrary display text during a call.  Sent in INFORMATION
messages.  Received from any message that the display text was not used as
a name.

If the display options are not set then the options default to legacy
behavior.

The arbitrary display text is exchanged between bridged channels using the
AST_FRAME_TEXT frame type.

To send display text from the dialplan use the SendText() application when
the arbitrary display text option is enabled.

JIRA SWP-2688
JIRA ABE-2693


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@306396 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-02-04 20:30:48 +00:00
Richard Mudgett ecdbb3d1d9 Merged from revision 304341
https://origsvn.digium.com/svn/asterisk/be/branches/C.3-bier

..........
  r304341 | rmudgett | 2011-01-26 16:38:39 -0600 (Wed, 26 Jan 2011) | 7 lines

  Add connected line chan_dahdi.conf pricpndialplan option.

  * Added from_channel value to prilocaldialplan option.

  JIRA ABE-2731
  JIRA SWP-2842
..........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@304385 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-01-27 00:06:27 +00:00
Richard Mudgett 7889af7cab Merged revisions 303771 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8

................
  r303771 | rmudgett | 2011-01-25 11:49:20 -0600 (Tue, 25 Jan 2011) | 54 lines
  
  Merged revisions 303769 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.6.2
  
  ................
    r303769 | rmudgett | 2011-01-25 11:42:42 -0600 (Tue, 25 Jan 2011) | 47 lines
    
    Merged revisions 303765 via svnmerge from 
    https://origsvn.digium.com/svn/asterisk/branches/1.4
    
    ........
      r303765 | rmudgett | 2011-01-25 11:36:50 -0600 (Tue, 25 Jan 2011) | 40 lines
      
      Sending out unnecessary PROCEEDING messages breaks overlap dialing.
      
      Issue #16789 was a good idea.  Unfortunately, it breaks overlap dialing
      through Asterisk.  There is not enough information available at this point
      to know if dialing is complete.  The ast_exists_extension(),
      ast_matchmore_extension(), and ast_canmatch_extension() calls are not
      adequate to detect a dial through extension pattern of "_9!".
      
      Workaround is to use the dialplan Proceeding() application early in
      non-dial through extensions.
      
      * Effectively revert issue #16789.
      
      * Allow outgoing overlap dialing to hear dialtone and other early media.
      A PROGRESS "inband-information is now available" message is now sent after
      the SETUP_ACKNOWLEDGE message for non-digital calls.  An
      AST_CONTROL_PROGRESS is now generated for incoming SETUP_ACKNOWLEDGE
      messages for non-digital calls.
      
      * Handling of the AST_CONTROL_CONGESTION in chan_dahdi/sig_pri was
      inconsistent with the cause codes.
      
      * Added better protection from sending out of sequence messages by
      combining several flags into a single enum value representing call
      progress level.
      
      * Added diagnostic messages for deferred overlap digits handling corner
      cases.
      
      (closes issue #17085)
      Reported by: shawkris
      
      (closes issue #18509)
      Reported by: wimpy
      Patches:
            issue18509_early_media_v1.8_v3.patch uploaded by rmudgett (license 664)
            Expanded upon issue18509_early_media_v1.8_v3.patch to include analog
            and SS7 because of backporting requirements.
      Tested by: wimpy, rmudgett
    ........
  ................
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@303772 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-01-25 17:58:00 +00:00
Richard Mudgett 90177fe708 Optional HOLD/RETRIEVE signaling for PTMP TE when the bridge goes on and off hold.
Added the moh_signaling option to specify what to do when the channel's
bridged peer puts the ISDN channel on and off of hold.

Implemented as a FSM to control libpri ISDN signaling when the bridged
peer places the channel on and off of hold with the AST_CONTROL_HOLD and
AST_CONTROL_UNHOLD control frames.

JIRA SWP-2687
JIRA ABE-2691

Review:	https://reviewboard.asterisk.org/r/1063/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@300212 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-01-04 16:38:28 +00:00
Tzafrir Cohen 6307b6fe3a Typos: recieved => received
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@299005 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-12-20 09:14:45 +00:00
Richard Mudgett ccdc417ab5 Merged revisions 296167 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8

................
  r296167 | rmudgett | 2010-11-24 16:49:48 -0600 (Wed, 24 Nov 2010) | 57 lines
  
  Merged revisions 296166 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.6.2
  
  ................
    r296166 | rmudgett | 2010-11-24 16:42:45 -0600 (Wed, 24 Nov 2010) | 50 lines
    
    Merged revisions 296165 via svnmerge from 
    https://origsvn.digium.com/svn/asterisk/branches/1.4
    
    ........
      r296165 | rmudgett | 2010-11-24 16:41:07 -0600 (Wed, 24 Nov 2010) | 43 lines
      
      Oneway audio to SIP phone from FXS port after FXS port gets a CallWaiting pip.
      
      The FXS connected phone has to have CW/CID support to fail, as it will
      send back a DTMF 'A' or 'D' when it's ready to receive CallerID.  A normal
      phone with no CID never fails.  Also the SIP phone does not hear MOH when
      the CW call is answered.
      
      The DTMF end frame is suppressed when the phone acknowledges the CW signal
      for CID.  The problem is the DTMF begin frame needs to be suppressed as
      well.  The DTMF begin frame is causing SIP to start sending the DTMF RTP
      frames.  Since the DTMF end frame is suppressed, SIP will not stop sending
      those DTMF RTP packets.
      
      * Suppress the DTMF begin and end frames when the channel driver is
      looking for DTMF digits.
      
      * Fixed a couple issues caused by not cleaning up the CID spill if you
      answer the CW call while it is sending the CID spill.
      
      * Fixed not sending CW/CID spill to the phone when the call is natively
      bridged.  (Fixed by not using native bridge if CW/CID is possible.)
      
      * Suppress received audio when sending CW/CID spills.  The other parties
      involved do not need to hear the CW/CID spills and may be confused if the
      CW call is for them.
      
      (closes issue #18129)
      Reported by: alecdavis
      Patches:
            issue_18129_v1.8_v3.patch uploaded by rmudgett (license 664)
      Tested by: alecdavis, rmudgett
      
      
      NOTE:
      
      * v1.4 does not have the main problem fixed by suppressing the DTMF start
      frames.  The other three items fixed are relevant.
      
      * If you really must restore native bridging between analog ports, you
      need to disable CW/CID either by configuring chan_dahdi.conf
      callwaitingcallerid=no or dialing *70 before dialing the number to
      temporarily disable CW.
    ........
  ................
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@296168 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-11-24 22:52:07 +00:00
Richard Mudgett 5d1cd7863a Merged revisions 294823 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8

................
  r294823 | rmudgett | 2010-11-11 20:45:22 -0600 (Thu, 11 Nov 2010) | 25 lines
  
  Merged revisions 294822 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.6.2
  
  ................
    r294822 | rmudgett | 2010-11-11 20:44:12 -0600 (Thu, 11 Nov 2010) | 18 lines
    
    Merged revisions 294821 via svnmerge from 
    https://origsvn.digium.com/svn/asterisk/branches/1.4
    
    ........
      r294821 | rmudgett | 2010-11-11 20:41:13 -0600 (Thu, 11 Nov 2010) | 11 lines
      
      Asterisk is getting a "No D-channels available!" warning message every 4 seconds.
      
      Asterisk is just whining too much with this message: "No D-channels
      available!  Using Primary channel XXX as D-channel anyway!".
      
      Filtered the message so it only comes out once if there is no D channel
      available without an intervening D channel available period.
      
      (closes issue #17270)
      Reported by: jmls
    ........
  ................
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@294824 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-11-12 02:46:03 +00:00
Richard Mudgett 3403dbf374 Merged revisions 284779-284780 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8

........
  r284779 | rmudgett | 2010-09-02 15:59:12 -0500 (Thu, 02 Sep 2010) | 8 lines
  
  Made output libpri event names if pri debugging is enabled when sig_pri processes them.
  
  * Simplified CLI "pri debug xx span xx" command code and removed redundant
  debugging enabled messages.
  
  * Made CLI "pri debug xx span xx" command only close the debugging log
  file if it was opened.
........
  r284780 | rmudgett | 2010-09-02 16:02:54 -0500 (Thu, 02 Sep 2010) | 2 lines
  
  Simplified pri_dchannel() poll timeout duration code.
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@284782 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-09-02 21:08:41 +00:00
Richard Mudgett 6a8c623ed2 Merged revisions 282671-282672 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8

........
  r282671 | rmudgett | 2010-08-18 10:27:51 -0500 (Wed, 18 Aug 2010) | 1 line
  
  Use the correct operator when calculating the PRI span devstate.
........
  r282672 | rmudgett | 2010-08-18 10:28:27 -0500 (Wed, 18 Aug 2010) | 1 line
  
  Use the correct type for aoce_delayhangup bit field.
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@282673 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-08-18 15:35:23 +00:00
Richard Mudgett 301505c4c4 Rename sig_pri_pri to sig_pri_span. More descriptive of concept.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@278942 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-07-23 15:41:44 +00:00
Richard Mudgett 93a5e74e37 Add digit manipulation tag support to chan_dahdi/sig_pri like chan_misdn.
Add the append_msn_to_cid_tag option to chan_dahdi like chan_misdn.

Review:	https://reviewboard.asterisk.org/r/696/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@270219 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-06-14 15:55:35 +00:00
Leif Madsen c672763af8 Fix some doxygen warnings.
(closes issue #17336)
Reported by: snuffy
Patches:
      doxygen-fixes1.diff uploaded by snuffy (license 35)
Tested by: russell

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@268969 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-06-08 14:38:18 +00:00
Richard Mudgett 0122ccd29c Extract sig_ss7 out of chan_dahdi.
Extract the SS7 specific code out of chan_dahdi like what was done to
ISDN/PRI and analog signaling.  The new SS7 structures were modeled on
sig_pri.

The changes to sig_pri are an enhancement and a bug fix made possible
because SS7 was extracted.

1) The sig_pri TRANSFERCAPABILITY channel variable should have been set
unconditionally in sig_pri_new_ast_channel().

2) SS7/PRI transfer capability interaction in dahdi_new() fixed because of
SS7 extraction.

3) Module ref count error in dahdi_new() if startpbx failed to start the
PBX for some reason.

Review:	https://reviewboard.asterisk.org/r/661/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@268774 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-06-07 20:04:42 +00:00
Richard Mudgett 1c67f208a7 Add ETSI Message Waiting Indication (MWI) support.
Add the ability to report waiting messages to ISDN endpoints (phones).

Relevant specification: EN 300 650 and EN 300 745

Review:	https://reviewboard.asterisk.org/r/599/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@267399 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-06-03 00:02:14 +00:00