aboutsummaryrefslogtreecommitdiffstats
path: root/channels/chan_dahdi.c
diff options
context:
space:
mode:
authorjpeeler <jpeeler@f38db490-d61c-443f-a65b-d21fe96a405b>2010-03-03 19:13:35 +0000
committerjpeeler <jpeeler@f38db490-d61c-443f-a65b-d21fe96a405b>2010-03-03 19:13:35 +0000
commit245d8b9027e3a0c3543fe27b48f6b6bda8683727 (patch)
tree2dc1925d9588faaa4a749b75612ac257a3d21078 /channels/chan_dahdi.c
parentdc906beb75c54f4dcedbfd1a6cda328bfaac3e6e (diff)
Merged revisions 250481 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ................ r250481 | jpeeler | 2010-03-03 13:06:06 -0600 (Wed, 03 Mar 2010) | 22 lines Merged revisions 250480 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r250480 | jpeeler | 2010-03-03 13:04:11 -0600 (Wed, 03 Mar 2010) | 15 lines Make sure to clear red alarm after polarity reversal. From the issue: The automatic overnight line tests (or manual ones) used on UK (BT) lines causes a red alarm on a dahdi / TDM400P connected channel. This is because the line uses voltage tests (battery loss) and polarity reversal. The polarity reversal causes chan_dahdi to initiate v23 CallerID processing but during this the event DAHDI_EVENT_NOALARM is ignored so that the alarm is never cleared. (closes issue #14163) Reported by: jedi98 Patches: chan_dahdi-1.4-inalarm.diff uploaded by jedi98 (license 653) Tested by: mattbrown, Chainsaw, mikeeccleston ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@250484 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels/chan_dahdi.c')
-rw-r--r--channels/chan_dahdi.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/channels/chan_dahdi.c b/channels/chan_dahdi.c
index 309876f72..0883355a4 100644
--- a/channels/chan_dahdi.c
+++ b/channels/chan_dahdi.c
@@ -8434,6 +8434,9 @@ static void *ss_thread(void *data)
if (i & DAHDI_IOMUX_SIGEVENT) {
res = dahdi_get_event(p->subs[idx].dfd);
ast_log(LOG_NOTICE, "Got event %d (%s)...\n", res, event2str(res));
+ if (res == DAHDI_EVENT_NOALARM) {
+ p->inalarm = 0;
+ }
if (p->cid_signalling == CID_SIG_V23_JP) {
if (res == DAHDI_EVENT_RINGBEGIN) {
@@ -8535,6 +8538,9 @@ static void *ss_thread(void *data)
if (i & DAHDI_IOMUX_SIGEVENT) {
res = dahdi_get_event(p->subs[idx].dfd);
ast_log(LOG_NOTICE, "Got event %d (%s)...\n", res, event2str(res));
+ if (res == DAHDI_EVENT_NOALARM) {
+ p->inalarm = 0;
+ }
res = 0;
/* Let us detect distinctive ring */
@@ -8684,6 +8690,9 @@ static void *ss_thread(void *data)
if (i & DAHDI_IOMUX_SIGEVENT) {
res = dahdi_get_event(p->subs[idx].dfd);
ast_log(LOG_NOTICE, "Got event %d (%s)...\n", res, event2str(res));
+ if (res == DAHDI_EVENT_NOALARM) {
+ p->inalarm = 0;
+ }
/* If we get a PR event, they hung up while processing calerid */
if ( res == DAHDI_EVENT_POLARITY && p->hanguponpolarityswitch && p->polarity == POLARITY_REV) {
ast_log(LOG_DEBUG, "Hanging up due to polarity reversal on channel %d while detecting callerid\n", p->channel);
@@ -8753,6 +8762,9 @@ static void *ss_thread(void *data)
if (i & DAHDI_IOMUX_SIGEVENT) {
res = dahdi_get_event(p->subs[idx].dfd);
ast_log(LOG_NOTICE, "Got event %d (%s)...\n", res, event2str(res));
+ if (res == DAHDI_EVENT_NOALARM) {
+ p->inalarm = 0;
+ }
res = 0;
/* Let us detect callerid when the telco uses distinctive ring */