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/branches/10@332265 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Richard Mudgett
2011-08-17 16:01:29 +00:00
parent 36f0a24040
commit cbfbbbeb32
7 changed files with 32223 additions and 5058 deletions
+13
View File
@@ -12555,6 +12555,9 @@ static struct dahdi_pvt *mkintf(int channel, const struct dahdi_chan_conf *conf,
#endif /* defined(HAVE_PRI_CALL_WAITING) */
pris[span].pri.transfer = conf->chan.transfer;
pris[span].pri.facilityenable = conf->pri.pri.facilityenable;
#if defined(HAVE_PRI_L2_PERSISTENCE)
pris[span].pri.l2_persistence = conf->pri.pri.l2_persistence;
#endif /* defined(HAVE_PRI_L2_PERSISTENCE) */
#if defined(HAVE_PRI_AOC_EVENTS)
pris[span].pri.aoc_passthrough_flag = conf->pri.pri.aoc_passthrough_flag;
pris[span].pri.aoce_delayhangup = conf->pri.pri.aoce_delayhangup;
@@ -17782,6 +17785,16 @@ static int process_dahdi(struct dahdi_chan_conf *confp, const char *cat, struct
} else if (!strcasecmp(v->name, "datetime_send")) {
confp->pri.pri.datetime_send = dahdi_datetime_send_option(v->value);
#endif /* defined(HAVE_PRI_DATETIME_SEND) */
#if defined(HAVE_PRI_L2_PERSISTENCE)
} else if (!strcasecmp(v->name, "layer2_persistence")) {
if (!strcasecmp(v->value, "keep_up")) {
confp->pri.pri.l2_persistence = PRI_L2_PERSISTENCE_KEEP_UP;
} else if (!strcasecmp(v->value, "leave_down")) {
confp->pri.pri.l2_persistence = PRI_L2_PERSISTENCE_LEAVE_DOWN;
} else {
confp->pri.pri.l2_persistence = PRI_L2_PERSISTENCE_DEFAULT;
}
#endif /* defined(HAVE_PRI_L2_PERSISTENCE) */
#endif /* HAVE_PRI */
#if defined(HAVE_SS7)
} else if (!strcasecmp(v->name, "ss7type")) {
+3
View File
@@ -8593,6 +8593,9 @@ int sig_pri_start_pri(struct sig_pri_span *pri)
#if defined(HAVE_PRI_DATETIME_SEND)
pri_date_time_send_option(pri->pri, pri->datetime_send);
#endif /* defined(HAVE_PRI_DATETIME_SEND) */
#if defined(HAVE_PRI_L2_PERSISTENCE)
pri_persistent_layer2_option(pri->pri, pri->l2_persistence);
#endif /* defined(HAVE_PRI_L2_PERSISTENCE) */
pri->resetpos = -1;
if (ast_pthread_create_background(&pri->master, NULL, pri_dchannel, pri)) {
+4
View File
@@ -405,6 +405,10 @@ struct sig_pri_span {
int qsigchannelmapping; /*!< QSIG channel mapping type */
int discardremoteholdretrieval; /*!< shall remote hold or remote retrieval notifications be discarded? */
int facilityenable; /*!< Enable facility IEs */
#if defined(HAVE_PRI_L2_PERSISTENCE)
/*! Layer 2 persistence option. */
int l2_persistence;
#endif /* defined(HAVE_PRI_L2_PERSISTENCE) */
int dchan_logical_span[SIG_PRI_NUM_DCHANS]; /*!< Logical offset the DCHAN sits in */
int fds[SIG_PRI_NUM_DCHANS]; /*!< FD's for d-channels */
+11
View File
@@ -258,7 +258,18 @@
; transfer feature of an analog phone.
; The default is no.
;hold_disconnect_transfer=yes
; BRI PTMP layer 2 persistence.
; You should normally not need to set this option.
; You may need to set this option if your telco brings layer 1 down when
; the line is idle.
; <blank>: Use libpri default.
; keep_up: Bring layer 2 back up if peer takes it down.
; leave_down: Leave layer 2 down if peer takes it down. (Libpri default)
; (Layer 2 will be brought back up for an outgoing call.)
;
;layer2_persistence=leave_down
; PRI Out of band indications.
; Enable this to report Busy and Congestion on a PRI using out-of-band
; notification. Inband indication, as used by Asterisk doesn't seem to work
Vendored
+32183 -5051
View File
File diff suppressed because it is too large Load Diff
+2
View File
@@ -414,6 +414,7 @@ AST_EXT_LIB_SETUP([PGSQL], [PostgreSQL], [postgres])
AST_EXT_LIB_SETUP([POPT], [popt], [popt])
AST_EXT_LIB_SETUP([PORTAUDIO], [PortAudio], [portaudio])
AST_EXT_LIB_SETUP([PRI], [ISDN PRI], [pri])
AST_EXT_LIB_SETUP_DEPENDENT([PRI_L2_PERSISTENCE], [ISDN Layer 2 persistence option], [PRI], [pri])
AST_EXT_LIB_SETUP_DEPENDENT([PRI_DATETIME_SEND], [ISDN PRI Date/time ie send policy], [PRI], [pri])
AST_EXT_LIB_SETUP_DEPENDENT([PRI_MWI_V2], [ISDN PRI Message Waiting Indication (Fixed)], [PRI], [pri])
AST_EXT_LIB_SETUP_DEPENDENT([PRI_DISPLAY_TEXT], [ISDN PRI user display text IE contents during call], [PRI], [pri])
@@ -1826,6 +1827,7 @@ AST_EXT_LIB_CHECK([POPT], [popt], [poptStrerror], [popt.h])
AST_EXT_LIB_CHECK([PORTAUDIO], [portaudio], [Pa_GetDeviceCount], [portaudio.h])
AST_EXT_LIB_CHECK([PRI], [pri], [pri_connected_line_update], [libpri.h])
AST_EXT_LIB_CHECK([PRI_L2_PERSISTENCE], [pri], [pri_persistent_layer2_option], [libpri.h])
AST_EXT_LIB_CHECK([PRI_DATETIME_SEND], [pri], [pri_date_time_send_option], [libpri.h])
AST_EXT_LIB_CHECK([PRI_MWI_V2], [pri], [pri_mwi_indicate_v2], [libpri.h])
AST_EXT_LIB_CHECK([PRI_DISPLAY_TEXT], [pri], [pri_display_text], [libpri.h])
+7 -7
View File
@@ -589,6 +589,9 @@
/* Define to 1 if you have the ISDN PRI set_inbanddisconnect library. */
#undef HAVE_PRI_INBANDDISCONNECT
/* Define to 1 if you have the ISDN Layer 2 persistence option library. */
#undef HAVE_PRI_L2_PERSISTENCE
/* Define to 1 if you have the ISDN PRI Malicious Call ID library. */
#undef HAVE_PRI_MCID
@@ -830,16 +833,16 @@
/* Define to 1 if you have the `strtoq' function. */
#undef HAVE_STRTOQ
/* Define to 1 if `ifr_ifru.ifru_hwaddr' is a member of `struct ifreq'. */
/* Define to 1 if `ifr_ifru.ifru_hwaddr' is member of `struct ifreq'. */
#undef HAVE_STRUCT_IFREQ_IFR_IFRU_IFRU_HWADDR
/* Define to 1 if `st_blksize' is a member of `struct stat'. */
/* Define to 1 if `st_blksize' is member of `struct stat'. */
#undef HAVE_STRUCT_STAT_ST_BLKSIZE
/* Define to 1 if `cr_uid' is a member of `struct ucred'. */
/* Define to 1 if `cr_uid' is member of `struct ucred'. */
#undef HAVE_STRUCT_UCRED_CR_UID
/* Define to 1 if `uid' is a member of `struct ucred'. */
/* Define to 1 if `uid' is member of `struct ucred'. */
#undef HAVE_STRUCT_UCRED_UID
/* Define to 1 if you have the mISDN Supplemental Services library. */
@@ -1117,9 +1120,6 @@
/* Define to the one symbol short name of this package. */
#undef PACKAGE_TARNAME
/* Define to the home page for this package. */
#undef PACKAGE_URL
/* Define to the version of this package. */
#undef PACKAGE_VERSION