diff options
author | tzafrir <tzafrir@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2008-05-19 12:42:19 +0000 |
---|---|---|
committer | tzafrir <tzafrir@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2008-05-19 12:42:19 +0000 |
commit | 619379a49371ac44c87a89e237bb7f60c841d23a (patch) | |
tree | 9207951e6474eb627744f159b58cb0ef7d41cb34 /kernel/xpp/init_card_4_30 | |
parent | dd3fad8de5df2f25630d66154f209b6b7cbf4049 (diff) |
* Zaptel-1.2.x does not have zt_alarm_channel(). Move up the backward
compatibility kludge so it actually affect code (failed compilation on
zaptel-1.2 from Digium without (Closes issue #12654 ).
* Cleanup a compile warning in xpp/card_global.c .
* Fix regression in PRI init script (case of less than 4 modules).
* Update changelog and bump version.
Merged revisions 4304 via svnmerge from
http://svn.digium.com/svn/zaptel/branches/1.2
git-svn-id: http://svn.digium.com/svn/zaptel/branches/1.4@4305 5390a7c7-147a-4af0-8ec9-7488f05a26cb
Diffstat (limited to 'kernel/xpp/init_card_4_30')
-rwxr-xr-x | kernel/xpp/init_card_4_30 | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/kernel/xpp/init_card_4_30 b/kernel/xpp/init_card_4_30 index 872c695..25e6ec7 100755 --- a/kernel/xpp/init_card_4_30 +++ b/kernel/xpp/init_card_4_30 @@ -227,7 +227,6 @@ sub port_setup($) { my $LIM1_RL = 0 << 1; # RL (Remote Loopback) my $lim1 = 0xB0 | $LIM1_RL; - main::select_subunit($portno); PRI::gen "$portno WD 26 F6"; # XPM0: Pulse Shape Programming for R1=18Ohms PRI::gen "$portno WD 27 02"; # XPM1: ...3V Pulse Level at the line (Vp-p=6v) PRI::gen "$portno WD 28 00"; # XPM2: ~XLT (transmit line is not in the high impedance state) @@ -356,23 +355,26 @@ sub main() { my @ports; my $subunit; - logit "main(): Initializing chip"; + logit "main(): Initializing chip ($ENV{UNIT_SUBUNITS} ports)"; PRI::init_quad; - for($subunit = 0; $subunit < $ENV{UNIT_SUBUNITS}; $subunit++) { + # Must initialize all 4 ports, regardless how much there are + for($subunit = 0; $subunit < 4; $subunit++) { my $is_nt = 0; - main::select_subunit($subunit); #logit "main(): Initializing subunit $subunit is_nt=$is_nt"; my $p = PRI::Port->new( 'PORT_NUM' => $subunit, - 'PRI_NT' => $is_nt + 'PRI_NT' => $is_nt, + 'EXIST' => ($subunit < $ENV{UNIT_SUBUNITS}) ); $p->port_setup; push(@ports, $p); } PRI::finish_quad; foreach my $p (@ports) { - $p->write_pri_info; + if($p->{EXIST}) { + $p->write_pri_info; + } } } |