[asterisk-bugs] [DAHDI-linux 0013897]: [patch] Support for generic HFC-4S cards

Asterisk Bug Tracker noreply at bugs.digium.com
Mon Nov 24 21:13:45 CST 2008


A NOTE has been added to this issue. 
====================================================================== 
http://bugs.digium.com/view.php?id=13897 
====================================================================== 
Reported By:                tzafrir
Assigned To:                tzafrir
====================================================================== 
Project:                    DAHDI-linux
Issue ID:                   13897
Category:                   wcb4xxp
Reproducibility:            N/A
Severity:                   feature
Priority:                   normal
Status:                     confirmed
====================================================================== 
Date Submitted:             2008-11-13 16:17 CST
Last Modified:              2008-11-24 21:13 CST
====================================================================== 
Summary:                    [patch] Support for generic HFC-4S cards
Description: 
A patch to add some basic support of other HFC-4S -based PCI cards (such as
the ones made by Junghanns). 

Status: gets rid of the echo canceller messages when not needed, but still
needs work.

Specifically:
* It adds too broad a range of cards (which also include bero.net cards) 
* The range may include some 2-ports cards, which will probably not work.

Not yet tested to work, though it it is at least configured.

====================================================================== 

---------------------------------------------------------------------- 
 (0095459) zhulizhong (reporter) - 2008-11-24 21:13
 http://bugs.digium.com/view.php?id=13897#c95459 
---------------------------------------------------------------------- 
add a patch for OpenVox B200P/B400P/B800P PCI ID
==========================================================
--- org_base.c  2008-11-24 21:32:50.000000000 +0800
+++ base.c      2008-11-25 11:05:49.000000000 +0800
@@ -114,11 +114,13 @@
        int ports; /* FIXME: Assumed to be 4 */
        int has_ec;
 };
-
 static struct devtype wcb4xxp = { "Wildcard B410P", .ports = 4, .has_ec =
1 };
-static struct devtype hfc4s =   { "HFC-4S PCI",     .ports = 4 };
-
-
+static struct devtype hfc4s = { "HFC-4S Junghanns.NET quadBRI PCI",
.ports = 4 };
+static struct devtype hfc2s = { "HFC-4S Junghanns.NET duoBRI PCI", .ports
= 2 };
+static struct devtype hfc2s_OpenVox = { "HFC-2S OpenVox B200P", .ports =
2 };
+static struct devtype hfc4s_OpenVox = { "HFC-4S OpenVox B400P", .ports =
4 };
+static struct devtype hfc8s_OpenVox = { "HFC-8S OpenVox B800P", .ports =
8 };
+
 #if 0
 static const char *wcb4xxp_rcsdata = "$RCSfile: base.c,v $ $Revision:
5374 $";
 static const char *build_stamp = "" __DATE__ " " __TIME__ "";
@@ -1399,7 +1401,7 @@

        gpio = b4xxp_getreg8(b4, R_GPI_IN3);

-       for (i=0; i < 4; i++) {
+       for (i=0; i < b4->numspans; i++) {
                s = &b4->spans[i];
                s->parent = b4;
                s->port = i;
@@ -1757,8 +1759,7 @@
  * we have a 24.576MHz crystal, so the PCM clock is 2x the incoming
clock.
  */
        /* b4xxp_setreg8(b4, R_BRG_PCM_CFG, 0x02); */
-        b4xxp_setreg8(b4, R_BRG_PCM_CFG, V_PCM_CLK);
-
+  b4xxp_setreg8(b4, R_BRG_PCM_CFG, V_PCM_CLK);
        flush_pci();

        udelay(100);                            /* wait a bit for clock to
settle */
@@ -2518,7 +2519,8 @@
 */

 /* TODO: determine whether this is a 2, 4 or 8 port card */
-       b4->numspans = 4;
+       b4->numspans = dt->ports;
+  vpmsupport = dt->has_ec;
        b4->syncspan = -1;              /* sync span is unknown */
        if (b4->numspans > MAX_SPANS_PER_CARD) {
                dev_err(b4->dev, "Driver does not know how to handle a %d
span card!\n", b4->numspans);
@@ -2668,7 +2670,11 @@
        { 0xd161, 0xb410, PCI_ANY_ID, PCI_ANY_ID, 0, 0, (unsigned
long)&wcb4xxp },
        /* TODO: this is too generic. Replace with specific entries for
         * specific devices using sub vendor IDs: */
-       { 0x1397, 0x08b4, PCI_ANY_ID, PCI_ANY_ID, 0, 0, (unsigned
long)&hfc4s },
+       { 0x1397, 0x08b4, 0x1397, 0xe888, 0, 0, (unsigned
long)&hfc4s_OpenVox },
+       { 0x1397, 0x08b4, 0x1397, 0xe884, 0, 0, (unsigned
long)&hfc2s_OpenVox },
+       { 0x1397, 0x08b4, 0x1397, 0xe998, 0, 0, (unsigned
long)&hfc8s_OpenVox },
+       { 0x1397, 0x08b4, 0x1397, 0xb520, 0, 0, (unsigned long)&hfc4s },
+       { 0x1397, 0x08b4, 0x1397, 0xb556, 0, 0, (unsigned long)&hfc2s },
        { 0, }
 };
=========================================================
I will test mote test for B400P+wcb4xxp. there are two problems:
1) the LED of port 4(4 port card)does not turn on, but the calls can go
through.
2) the LEDs of ports does not change the status of connection. only red
color is there, even call is established or closed. 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2008-11-24 21:13 zhulizhong     Note Added: 0095459                          
======================================================================




More information about the asterisk-bugs mailing list