[Home]

Summary:DAHLIN-00221: [patch] FXS Module detection fails
Reporter:Bennie Sexton (bsexton)Labels:
Date Opened:2010-10-22 01:36:39Date Closed:2019-05-31 09:26:34
Priority:BlockerRegression?No
Status:Closed/CompleteComponents:wctdm24xxp
Versions:2.4.0 Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) dahdi-fxo-detect.diff
Description:The portion of the wctdm24xxp driver that does a check of reg1 to ensure that it has a value of 0x88 causes the driver to fail to load for my fxs modules. The card and modules that I have were purchased on Ebay. The cards I have return a value of 0x08 during the module detection phase causing the driver to not recognize my FXS modules. The cards work find with all versions of DAHDI/ZAP that were released prior to the inclusion of this code in the driver. Patching the driver to allow either 0x88 or 0x08 allows me to use DAHDI version 2.4.0 with no issues.
Comments:By: Khaled (khaled_alzowi) 2010-10-24 09:24:00

I have the same problem that asterisk 1.4.36 doesn't detect the fxs module on the TDM400P, I have tried this patch and it asked me which file to patch, I checked my system and there is no file called base.c to patch.

Please can you verify which file is meant to be patched with this patch.

By: Bennie Sexton (bsexton) 2010-10-24 10:20:42

This patch is not for Asterisk. It is for the wctdm24xxp driver included in the dahdi-linux package. The card I have is the TDM410P which requires the wctdm24xxp driver. If you do indeed have the TDM400P, it uses the wctdm driver which does not seem to include the piece of code that kept my FXS modules from being recognized.

If you are using the wctdm24xxp driver, the file that needs patched is in the drivers/dahdi/wctdm24xxp directory. You will need the dahdi-linux source which can be downloaded from http://downloads.asterisk.org/pub/telephony/dahdi-linux/releases. The card I am using was purchased from an Ebay vendor named Chinaroby.

By: Digium Subversion (svnbot) 2010-10-25 13:26:21

Repository: dahdi
Revision: 9456

U   linux/trunk/drivers/dahdi/wctdm24xxp/base.c

------------------------------------------------------------------------
r9456 | sruffell | 2010-10-25 13:26:20 -0500 (Mon, 25 Oct 2010) | 11 lines

wctdm24xxp: Detect FXS modules based on the 3210 SLIC.

Fixes a regression introduced in revision 5916 where FXS modules based
on the 3210 were not properly detected.

(closes issue DAHLIN-221)
Reported by: bsexton
Patches:
     dahdi-fxo-detect.diff uploaded by bsexton (license 1133)

Signed-off-by: Shaun Ruffell <sruffell@digium.com>
------------------------------------------------------------------------

http://svn.digium.com/view/dahdi?view=rev&revision=9456

By: Shaun Ruffell (sruffell) 2010-10-25 13:28:20

bsexton:  Thanks for the patch.

By: Digium Subversion (svnbot) 2011-01-20 23:30:27.000-0600

Repository: dahdi
Revision: 9675

U   linux/branches/2.4/drivers/dahdi/wctdm24xxp/base.c

------------------------------------------------------------------------
r9675 | sruffell | 2011-01-20 23:30:26 -0600 (Thu, 20 Jan 2011) | 13 lines

wctdm24xxp: Detect FXS modules based on the 3210 SLIC.

Fixes a regression introduced in revision 5916 where FXS modules based
on the 3210 were not properly detected.

(closes issue DAHLIN-221)
Reported by: bsexton
Patches:
     dahdi-fxo-detect.diff uploaded by bsexton (license 1133)

Signed-off-by: Shaun Ruffell <sruffell@digium.com>

Origin: http://svnview.digium.com/svn/dahdi?view=rev&rev=9456
------------------------------------------------------------------------

http://svn.digium.com/view/dahdi?view=rev&revision=9675

By: Bennie Sexton (bsexton) 2011-02-03 18:16:28.000-0600

Is there a reason that this patch has been removed from the SVN source?

By: Tzafrir Cohen (tzafrir) 2011-02-06 03:57:08.000-0600

From what I see, this code was removed in rev. 9720 ("wctdm24xxp: Remove code for unsupported modules.")

http://svnview.digium.com/svn/dahdi?revision=9720&view=revision

By: Bennie Sexton (bsexton) 2011-04-02 01:13:10

The card I have is NOT an S100M. I have S110 type modules. The patch I submitted earlier still compiles and works fine with my card and dahdi version 2.4.1.1. This patch was not specific to S100M modules.

By: Bennie Sexton (bsexton) 2011-04-04 07:09:41

Here is the output from the wctdm24xxp module with debug set to 1.

dahdi: Telephony Interface Registered on major 196
dahdi: Version: 2.4.1.1
PCI: Enabling device 0000:03:00.0 (0000 -> 0003)
ACPI: PCI Interrupt 0000:03:00.0[A] -> GSI 20 (level, low) -> IRQ 233
wctdm24xxp 0000:03:00.0: VoiceDAA System: 04
wctdm24xxp 0000:03:00.0: voicedaa: card 1 new timeslot: 0
wctdm24xxp 0000:03:00.0: ISO-Cap is now up, line side: 03 rev 06
wctdm24xxp 0000:03:00.0: setting FXO tx gain for card=0 to 0
wctdm24xxp 0000:03:00.0: setting FXO rx gain for card=0 to 0
wctdm24xxp 0000:03:00.0: DEBUG fxotxgain:0.0 fxorxgain:0.0
wctdm24xxp 0000:03:00.0: Port 1: Installed -- AUTO FXO (FCC mode)
wctdm24xxp 0000:03:00.0: Trying port 2 with alternate chip select
wctdm24xxp 0000:03:00.0: ProSLIC on module 1, product 0, version 5
wctdm24xxp 0000:03:00.0: ProSLIC on module 1 seems sane.
wctdm24xxp 0000:03:00.0: ProSLIC on module 1 powered up to -75 volts (c9) in 16 ms
wctdm24xxp 0000:03:00.0: Loop current set to 20mA!
wctdm24xxp 0000:03:00.0: Post-leakage voltage: 32 volts
wctdm24xxp 0000:03:00.0: ProSLIC on module 1 powered up to -75 volts (ca) in 12 ms
wctdm24xxp 0000:03:00.0: Loop current set to 20mA!
wctdm24xxp 0000:03:00.0: Calibration Vector Regs 98 - 107:
wctdm24xxp 0000:03:00.0: 98: 14
wctdm24xxp 0000:03:00.0: 99: 10
wctdm24xxp 0000:03:00.0: 100: 0e
wctdm24xxp 0000:03:00.0: 101: 10
wctdm24xxp 0000:03:00.0: 102: 07
wctdm24xxp 0000:03:00.0: 103: 46
wctdm24xxp 0000:03:00.0: 104: 05
wctdm24xxp 0000:03:00.0: 105: 2a
wctdm24xxp 0000:03:00.0: 106: 1f
wctdm24xxp 0000:03:00.0: 107: 08
wctdm24xxp 0000:03:00.0: Init Indirect Registers completed successfully.
wctdm24xxp 0000:03:00.0: proslic: card 2 new timeslot: 1
wctdm24xxp 0000:03:00.0: DEBUG: fxstxgain:0.0 fxsrxgain:0.0
wctdm24xxp 0000:03:00.0: Proslic module 1 loop current is 20mA
wctdm24xxp 0000:03:00.0: Port 2: Installed -- AUTO FXS/DPO
wctdm24xxp 0000:03:00.0: ProSLIC on module 2, product 0, version 5
wctdm24xxp 0000:03:00.0: ProSLIC on module 2 seems sane.
wctdm24xxp 0000:03:00.0: ProSLIC on module 2 powered up to -74 volts (c5) in 16 ms
wctdm24xxp 0000:03:00.0: Loop current set to 20mA!
wctdm24xxp 0000:03:00.0: Post-leakage voltage: 31 volts
wctdm24xxp 0000:03:00.0: ProSLIC on module 2 powered up to -74 volts (c6) in 12 ms
wctdm24xxp 0000:03:00.0: Loop current set to 20mA!
wctdm24xxp 0000:03:00.0: Calibration Vector Regs 98 - 107:
wctdm24xxp 0000:03:00.0: 98: 12
wctdm24xxp 0000:03:00.0: 99: 11
wctdm24xxp 0000:03:00.0: 100: 0e
wctdm24xxp 0000:03:00.0: 101: 0f
wctdm24xxp 0000:03:00.0: 102: 05
wctdm24xxp 0000:03:00.0: 103: 6b
wctdm24xxp 0000:03:00.0: 104: 05
wctdm24xxp 0000:03:00.0: 105: 2a
wctdm24xxp 0000:03:00.0: 106: 20
wctdm24xxp 0000:03:00.0: 107: 08
wctdm24xxp 0000:03:00.0: Init Indirect Registers completed successfully.
wctdm24xxp 0000:03:00.0: proslic: card 3 new timeslot: 2
wctdm24xxp 0000:03:00.0: DEBUG: fxstxgain:0.0 fxsrxgain:0.0
wctdm24xxp 0000:03:00.0: Proslic module 2 loop current is 20mA
wctdm24xxp 0000:03:00.0: Port 3: Installed -- AUTO FXS/DPO
wctdm24xxp 0000:03:00.0: ProSLIC on module 3, product 0, version 5
wctdm24xxp 0000:03:00.0: ProSLIC on module 3 seems sane.
wctdm24xxp 0000:03:00.0: ProSLIC on module 3 powered up to -74 volts (c7) in 16 ms
wctdm24xxp 0000:03:00.0: Loop current set to 20mA!
wctdm24xxp 0000:03:00.0: Post-leakage voltage: 31 volts
wctdm24xxp 0000:03:00.0: ProSLIC on module 3 powered up to -74 volts (c7) in 16 ms
wctdm24xxp 0000:03:00.0: Loop current set to 20mA!
wctdm24xxp 0000:03:00.0: Calibration Vector Regs 98 - 107:
wctdm24xxp 0000:03:00.0: 98: 10
wctdm24xxp 0000:03:00.0: 99: 10
wctdm24xxp 0000:03:00.0: 100: 0e
wctdm24xxp 0000:03:00.0: 101: 0e
wctdm24xxp 0000:03:00.0: 102: 04
wctdm24xxp 0000:03:00.0: 103: 77
wctdm24xxp 0000:03:00.0: 104: 05
wctdm24xxp 0000:03:00.0: 105: 2e
wctdm24xxp 0000:03:00.0: 106: 1f
wctdm24xxp 0000:03:00.0: 107: 08
wctdm24xxp 0000:03:00.0: Init Indirect Registers completed successfully.
wctdm24xxp 0000:03:00.0: proslic: card 4 new timeslot: 3
wctdm24xxp 0000:03:00.0: DEBUG: fxstxgain:0.0 fxsrxgain:0.0
wctdm24xxp 0000:03:00.0: Proslic module 3 loop current is 20mA
wctdm24xxp 0000:03:00.0: Port 4: Installed -- AUTO FXS/DPO
wctdm24xxp 0000:03:00.0: fixup_analog: x=0, y=0 modtype=2, s->chans[0]=ffff81011e65f000
wctdm24xxp 0000:03:00.0: fixup_analog: x=1, y=1 modtype=1, s->chans[1]=ffff81009100e000
wctdm24xxp 0000:03:00.0: fixup_analog: x=2, y=2 modtype=1, s->chans[2]=ffff8101279b8000
wctdm24xxp 0000:03:00.0: fixup_analog: x=3, y=3 modtype=1, s->chans[3]=ffff810048fbb000
wctdm24xxp 0000:03:00.0: voicedaa: card 1 new timeslot: 0
wctdm24xxp 0000:03:00.0: proslic: card 2 new timeslot: 1
wctdm24xxp 0000:03:00.0: proslic: card 3 new timeslot: 2
wctdm24xxp 0000:03:00.0: proslic: card 4 new timeslot: 3
wctdm24xxp 0000:03:00.0: Found a Wildcard TDM: Wildcard TDM410P (0 BRI spans, 4 analog channels)
dahdi: Registered tone zone 0 (United States / North America)
wctdm24xxp 0000:03:00.0: 4582883456 Polarity reversed (0 -> 1)
wctdm24xxp 0000:03:00.0: BATTERY on 1/1 (+)!
wctdm24xxp 0000:03:00.0: -- Setting echo registers:
wctdm24xxp 0000:03:00.0: -- Set echo registers successfully