[Pkg-voip-commits] r5144 - in /zaptel/trunk/debian: changelog patches/beronet.dpatch
tzafrir-guest at alioth.debian.org
tzafrir-guest at alioth.debian.org
Sun Dec 30 14:25:08 UTC 2007
Author: tzafrir-guest
Date: Sun Dec 30 14:25:08 2007
New Revision: 5144
URL: http://svn.debian.org/wsvn/pkg-voip/?sc=1&rev=5144
Log:
beronet.dpatch: Support for Bero.net cards (Closes: #453496).
Added:
zaptel/trunk/debian/patches/beronet.dpatch (with props)
Modified:
zaptel/trunk/debian/changelog
Modified: zaptel/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-voip/zaptel/trunk/debian/changelog?rev=5144&op=diff
==============================================================================
--- zaptel/trunk/debian/changelog (original)
+++ zaptel/trunk/debian/changelog Sun Dec 30 14:25:08 2007
@@ -1,3 +1,9 @@
+zaptel (1:1.4.7.1~dfsg-2) UNRELEASED; urgency=low
+
+ * beronet.dpatch: Support for Bero.net cards (Closes: #453496).
+
+ -- Tzafrir Cohen <tzafrir.cohen at xorcom.com> Sun, 30 Dec 2007 11:29:21 +0200
+
zaptel (1:1.4.7.1~dfsg-1) unstable; urgency=low
[ Tzafrir Cohen ]
Added: zaptel/trunk/debian/patches/beronet.dpatch
URL: http://svn.debian.org/wsvn/pkg-voip/zaptel/trunk/debian/patches/beronet.dpatch?rev=5144&op=file
==============================================================================
--- zaptel/trunk/debian/patches/beronet.dpatch (added)
+++ zaptel/trunk/debian/patches/beronet.dpatch Sun Dec 30 14:25:08 2007
@@ -1,0 +1,493 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## beronet.dpatch by Tzafrir Cohen <tzafrir.cohen at xorcom.com>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Support bero.net cards in qozap and cwain Zaptel drivers.
+## DP: Source: http://blog.eth0.cc/zaptel-patchwork/
+
+ at DPATCH@
+diff -urNad zaptel-1.4.7.1~dfsg~/cwain/cwain.c zaptel-1.4.7.1~dfsg/cwain/cwain.c
+--- zaptel-1.4.7.1~dfsg~/cwain/cwain.c 2007-12-30 10:26:20.000000000 +0200
++++ zaptel-1.4.7.1~dfsg/cwain/cwain.c 2007-12-30 10:44:27.000000000 +0200
+@@ -12,6 +12,13 @@
+ * This program is free software and may be modified and
+ * distributed under the terms of the GNU Public License.
+ *
++ * Patched to recognize and support BN1E1 and BN2E1(+) boards
++ * by Daniel Scheller <scheller at loca.net> or <www at eth0.cc>
++ *
++ * The patch is (C) 2007 LocaNet oHG. It is free software and
++ * may be modified and distributed under the terms of the GNU
++ * General Public License.
++ *
+ */
+ #include <linux/kernel.h>
+ #include <linux/module.h>
+@@ -153,7 +160,7 @@
+ if (!(cwaintmp->span.flags & ZT_FLAG_RUNNING)) {
+ return;
+ }
+- if ((cwaintmp->type == 0xb553) || (cwaintmp->type == 0xb554)) {
++ if ((cwaintmp->type == 0xb553) || (cwaintmp->type == 0xb554) || (cwaintmp->type == 0xb563) || (cwaintmp->type == 0xb564) || (cwaintmp->type == 0xb565)) {
+ /* sync status */
+ if (((cwaintmp->sync_sta & 0x07) == 0x07) && cwaintmp->sync) {
+ cwaintmp->leds[0] = 1;
+@@ -294,7 +301,7 @@
+ }
+ spin_unlock(&cwain_span_registerlock);
+
+- if (cwainspan->type == 0xb553) {
++ if ((cwainspan->type == 0xb553) || (cwainspan->type == 0xb563)) {
+ cwaintmp = kmalloc(sizeof(struct zt_cwain_card),GFP_KERNEL);
+ if (!cwaintmp) {
+ printk(KERN_WARNING "cwain: unable to kmalloc!\n");
+@@ -309,10 +316,20 @@
+ cwaintmp->spans = 1;
+ cwaintmp->cardID = cwainspan->cardID;
+ cwain_register_card(cwaintmp);
+- printk(KERN_INFO
+- "cwain: Junghanns.NET singleE1 PCI ISDN card configured at mem %lx IRQ %d HZ %d CardID %d\n",
+- (unsigned long) cwainspan->pci_io,
+- cwaintmp->span[0]->irq, HZ, cwainspan->cardID);
++
++ switch(cwainspan->type)
++ {
++ case 0xb553 : printk(KERN_INFO
++ "cwain: Junghanns.NET singleE1 PCI ISDN card configured at mem %lx IRQ %d HZ %d CardID %d\n",
++ (unsigned long) cwainspan->pci_io,
++ cwaintmp->span[0]->irq, HZ, cwainspan->cardID);
++ break;
++ case 0xb563 : printk(KERN_INFO
++ "cwain: BeroNet BN1E1 (single HFC-E1) PCI ISDN card configured at mem %lx IRQ %d HZ %d CardID %d\n",
++ (unsigned long) cwainspan->pci_io,
++ cwaintmp->span[0]->irq, HZ, cwainspan->cardID);
++ break;
++ }
+ } else {
+ cwaintmp = cwain_get_card(cwainspan->pcibus);
+ if (!cwaintmp) {
+@@ -325,13 +342,21 @@
+
+ spin_lock_init(&cwaintmp->lock);
+ cwaintmp->pcibus = cwainspan->pcibus;
+- cwaintmp->spans = cwainspan->type - 46419;
++ cwaintmp->spans = 1;
+ cwaintmp->span[0] = cwainspan;
+ cwaintmp->cardID = cwainspan->cardID;
+ cwaintmp->syncs[0] = -1;
+ cwain_register_card(cwaintmp);
+ } else {
+- cwaintmp->spans = cwainspan->type - 46418;
++ switch (cwainspan->type) {
++ case 0xb554 :
++ case 0xb564 :
++ case 0xb565 : cwaintmp->spans = 2;
++ break;
++ default : cwaintmp->spans = 0;
++ break;
++ }
++
+ if (cwainspan->cardID < cwaintmp->cardID) {
+ cwaintmp->cardID = cwainspan->cardID;
+ cwaintmp->span[1] = cwaintmp->span[0];
+@@ -341,10 +366,30 @@
+ cwaintmp->span[1] = cwainspan;
+ cwaintmp->syncs[1] = -1;
+ }
+- printk(KERN_INFO
+- "cwain: Junghanns.NET doubleE1 PCI ISDN card configured at mem (%lx / %lx) IRQ %d HZ %d CardID (%d / %d) bus %#x\n",
+- (unsigned long) cwaintmp->span[0]->pci_io, (unsigned long) cwaintmp->span[1]->pci_io,
+- cwaintmp->span[0]->irq, HZ, cwaintmp->span[0]->cardID, cwaintmp->span[1]->cardID, cwaintmp->pcibus);
++
++ switch (cwainspan->type) {
++ case 0xb554 : printk(KERN_INFO
++ "cwain: Junghanns.NET doubleE1 PCI ISDN card configured at mem (%lx / %lx) IRQ %d HZ %d CardID (%d / %d) bus %#x\n",
++ (unsigned long) cwaintmp->span[0]->pci_io, (unsigned long) cwaintmp->span[1]->pci_io,
++ cwaintmp->span[0]->irq, HZ, cwaintmp->span[0]->cardID, cwaintmp->span[1]->cardID, cwaintmp->pcibus);
++ break;
++ case 0xb564 : printk(KERN_INFO
++ "cwain: BeroNet BN2E1 (dual HFC-E1) PCI ISDN card configured at mem (%lx / %lx) IRQ %d HZ %d CardID (%d / %d) bus %#x\n",
++ (unsigned long) cwaintmp->span[0]->pci_io, (unsigned long) cwaintmp->span[1]->pci_io,
++ cwaintmp->span[0]->irq, HZ, cwaintmp->span[0]->cardID, cwaintmp->span[1]->cardID, cwaintmp->pcibus);
++ break;
++ case 0xb565 : printk(KERN_INFO
++ "cwain: BeroNet BN2E1 (+) (dual HFC-E1 w/failover) PCI ISDN card configured at mem (%lx / %lx) IRQ %d HZ %d CardID (%d / %d) bus %#x\n",
++ (unsigned long) cwaintmp->span[0]->pci_io, (unsigned long) cwaintmp->span[1]->pci_io,
++ cwaintmp->span[0]->irq, HZ, cwaintmp->span[0]->cardID, cwaintmp->span[1]->cardID, cwaintmp->pcibus);
++ break;
++ default : printk(KERN_INFO
++ "cwain: Unknown HFC-E1 PCI ISDN card configured at mem (%lx / %lx) IRQ %d HZ %d CardID (%d / %d) bus %#x\n",
++ (unsigned long) cwaintmp->span[0]->pci_io, (unsigned long) cwaintmp->span[1]->pci_io,
++ cwaintmp->span[0]->irq, HZ, cwaintmp->span[0]->cardID, cwaintmp->span[1]->cardID, cwaintmp->pcibus);
++ break;
++ }
++
+ }
+ }
+ return 0;
+@@ -1232,6 +1277,15 @@
+ case 0xb554:
+ sprintf(cwainspan->span.desc,"Junghanns.NET doubleE1 PCI ISDN Card %d (cardID %d) (1 E1 port) SYNCED",cwainspan->cardno,cwainspan->cardID);
+ break;
++ case 0xb563:
++ sprintf(cwainspan->span.desc,"BeroNet BN1E1 (single HFC-E1) PCI ISDN Card %d (cardID %d) SYNCED",cwainspan->cardno,cwainspan->cardID);
++ break;
++ case 0xb564:
++ sprintf(cwainspan->span.desc,"BeroNet BN2E1 (dual HFC-E1) PCI ISDN Card %d (cardID %d) (1 E1 port) SYNCED",cwainspan->cardno,cwainspan->cardID);
++ break;
++ case 0xb565:
++ sprintf(cwainspan->span.desc,"BeroNet BN2E1 (+) (dual HFC-E1 w/failover) PCI ISDN Card %d (cardID %d) (1 E1 port) SYNCED",cwainspan->cardno,cwainspan->cardID);
++ break;
+ }
+ } else {
+ switch (cwainspan->type) {
+@@ -1241,6 +1295,15 @@
+ case 0xb554:
+ sprintf(cwainspan->span.desc,"Junghanns.NET doubleE1 PCI ISDN Card %d (cardID %d) (1 E1 port) NO SYNC (sync_sta = %#x)",cwainspan->cardno,cwainspan->cardID, sync_sta);
+ break;
++ case 0xb563:
++ sprintf(cwainspan->span.desc,"BeroNet BN1E1 (single HFC-E1) PCI ISDN Card %d (cardID %d) NO SYNC (sync_sta = %#x)",cwainspan->cardno,cwainspan->cardID, sync_sta);
++ break;
++ case 0xb564:
++ sprintf(cwainspan->span.desc,"BeroNet BN2E1 (dual HFC-E1) PCI ISDN Card %d (cardID %d) (1 E1 port) NO SYNC (sync_sta = %#x)",cwainspan->cardno,cwainspan->cardID, sync_sta);
++ break;
++ case 0xb565:
++ sprintf(cwainspan->span.desc,"BeroNet BN2E1 (+) (dual HFC-E1 w/failover) PCI ISDN Card %d (cardID %d) (1 E1 port) NO SYNC (sync_sta = %#x)",cwainspan->cardno,cwainspan->cardID, sync_sta);
++ break;
+ }
+ }
+ cwain_doLEDs(cwainspan);
+@@ -1862,6 +1925,15 @@
+ case 0xb554:
+ sprintf(cwaintmp->span.desc,"Junghanns.NET doubleE1 PCI ISDN Card %d (cardID %d) (1 E1 port)",cwaintmp->cardno,cwaintmp->cardID);
+ break;
++ case 0xb563:
++ sprintf(cwaintmp->span.desc,"BeroNet BN1E1 (single HFC-E1) PCI ISDN Card %d (cardID %d)",cwaintmp->cardno,cwaintmp->cardID);
++ break;
++ case 0xb564:
++ sprintf(cwaintmp->span.desc,"BeroNet BN2E1 (dual HFC-E1) PCI ISDN Card %d (cardID %d) (1 E1 port)",cwaintmp->cardno,cwaintmp->cardID);
++ break;
++ case 0xb565:
++ sprintf(cwaintmp->span.desc,"BeroNet BN2E1 (+) (dual HFC-E1 w/failover) PCI ISDN Card %d (cardID %d) (1 E1 port)",cwaintmp->cardno,cwaintmp->cardID);
++ break;
+ default:
+ return -1;
+ }
+@@ -2038,7 +2110,7 @@
+ /* disable interrupts */
+ cwain_outb(cwaintmp,cwain_R_IRQ_CTRL, 0);
+
+- if (((tmp->subsystem_device==0xb553) || (tmp->subsystem_device==0xb554))&& (pcidid == PCI_DEVICE_ID_CCD_E)) {
++ if (((tmp->subsystem_device==0xb553) || (tmp->subsystem_device==0xb554) || (tmp->subsystem_device==0xb563) || (tmp->subsystem_device==0xb564) || (tmp->subsystem_device==0xb565))&& (pcidid == PCI_DEVICE_ID_CCD_E)) {
+ dips = (cwain_inb(cwaintmp,cwain_R_GPI_IN0) >> 5);
+ cid = 7;
+ for (i=0;i<3;i++) {
+diff -urNad zaptel-1.4.7.1~dfsg~/qozap/qozap.c zaptel-1.4.7.1~dfsg/qozap/qozap.c
+--- zaptel-1.4.7.1~dfsg~/qozap/qozap.c 2007-12-30 10:26:21.000000000 +0200
++++ zaptel-1.4.7.1~dfsg/qozap/qozap.c 2007-12-30 10:44:21.000000000 +0200
+@@ -9,6 +9,14 @@
+ * This program is free software and may be modified and
+ * distributed under the terms of the GNU Public License.
+ *
++ * Patched to recognize and support BN2S0, BN4S0, BN8S0 and BN8S0+
++ * by Daniel Scheller <scheller at loca.net> or <www at eth0.cc> and
++ * Henning Holtschneider <henning at loca.net>
++ *
++ * The patch is (C) 2006, 2007 LocaNet oHG. It is free software and
++ * may be modified and distributed under the terms of the GNU Public
++ * License.
++ *
+ */
+ #include <linux/kernel.h>
+ #include <linux/module.h>
+@@ -112,7 +120,7 @@
+ unsigned long flags;
+ spin_lock_irqsave(&qoztmp->lock,flags);
+
+- if ((qoztmp->type == 0xb520) && (qoztmp->stports == 4)){
++ if (((qoztmp->type == 0xb520) || (qoztmp->type == 0xb560)) && (qoztmp->stports == 4)){
+ qoz_outb(qoztmp,qoz_R_GPIO_SEL,0x20 | 0x10);
+ qoz_outb(qoztmp,qoz_R_GPIO_EN1,0xf);
+ qoz_outb(qoztmp,qoz_R_GPIO_OUT1,(qoztmp->leds[0] | (qoztmp->leds[1] << 1) | (qoztmp->leds[2] << 2) | (qoztmp->leds[3] << 3)));
+@@ -147,7 +155,7 @@
+ */
+ qoz_outb(qoztmp,qoz_R_GPIO_OUT1, leds);
+
+- } else if ((qoztmp->type == 0xb556) && (qoztmp->stports == 2)){
++ } else if (((qoztmp->type == 0xb556) || (qoztmp->type == 0xb566)) && (qoztmp->stports == 2)){
+ qoz_outb(qoztmp,qoz_R_GPIO_SEL,0x80 | 0x40 | 0x20 | 0x10);
+ qoz_outb(qoztmp,qoz_R_GPIO_EN1,0xff);
+ leds = 0x0;
+@@ -159,7 +167,7 @@
+ }
+ qoz_outb(qoztmp,qoz_R_GPIO_OUT1, leds);
+
+- } else if (qoztmp->type == 0xb558) {
++ } else if ((qoztmp->type == 0xb558) || (qoztmp->type == 0xb568)) {
+ qoz_outb(qoztmp,qoz_R_GPIO_SEL,0x80 | 0x40 | 0x20);
+ qoz_outb(qoztmp,qoz_R_GPIO_EN1,0x80 | 0x40 | 0x20 | 0x4);
+ if (qoztmp->leds[0] == 1) {
+@@ -182,7 +190,7 @@
+ gpio_15 2
+ gpio_14 3
+ */
+- } else if (qoztmp->type == 0xb55b) {
++ } else if ((qoztmp->type == 0xb55b) || (qoztmp->type == 0xb56b)) {
+ qoz_outb(qoztmp,qoz_R_BRG_PCM_CFG,0x21);
+ /* 0x01 g1 st1
+ 0x02 g2 st2
+@@ -302,9 +310,9 @@
+
+ /* set S0 amplitude */
+ qoz_outb(qoztmp,qoz_R_PWM_MD,0xa0);
+- if (qoztmp->type == 0xb552) {
++ if ((qoztmp->type == 0xb552) || (qoztmp->type == 0xb562)) {
+ qoz_outb(qoztmp,qoz_R_PWM0,0x19);
+- } else if (qoztmp->type == 0xb55b) {
++ } else if ((qoztmp->type == 0xb55b) || (qoztmp->type == 0xb56b)) {
+ qoz_outb(qoztmp,qoz_R_PWM0,0x19);
+ } else {
+ qoz_outb(qoztmp,qoz_R_PWM0,0x1E);
+@@ -318,9 +326,9 @@
+ /* all state changes */
+ qoz_outb(qoztmp,qoz_R_SCI_MSK, 0xff);
+
+- if (qoztmp->type == 0xb552) {
++ if ((qoztmp->type == 0xb552) || (qoztmp->type == 0xb562)) {
+ qoz_outb(qoztmp,qoz_R_FIFO_MD,0x16);
+- } else if (qoztmp->type == 0xb55b) {
++ } else if ((qoztmp->type == 0xb55b) || (qoztmp->type == 0xb56b)) {
+ qoz_outb(qoztmp,qoz_R_FIFO_MD,0x16);
+ } else {
+ qoz_outb(qoztmp,qoz_R_FIFO_MD,0x26);
+@@ -335,13 +343,13 @@
+ qoz_outb(qoztmp,qoz_R_BRG_PCM_CFG,0x0);
+ } else if (qoztmp->type == 0xb550) {
+ qoz_outb(qoztmp,qoz_R_BRG_PCM_CFG,0x20);
+- } else if (qoztmp->type == 0xb556) {
++ } else if ((qoztmp->type == 0xb556) || (qoztmp->type == 0xb566)) {
+ qoz_outb(qoztmp,qoz_R_BRG_PCM_CFG,0x20);
+ } else if (qoztmp->type == 0xb557) {
+ qoz_outb(qoztmp,qoz_R_BRG_PCM_CFG,0x20);
+- } else if (qoztmp->type == 0xb558) {
++ } else if ((qoztmp->type == 0xb558) || (qoztmp->type == 0xb568)) {
+ qoz_outb(qoztmp,qoz_R_BRG_PCM_CFG,0x20);
+- } else if (qoztmp->type == 0xb520) {
++ } else if ((qoztmp->type == 0xb520) || (qoztmp->type == 0xb560)) {
+ qoz_outb(qoztmp,qoz_R_BRG_PCM_CFG,0x20);
+ } else {
+ /* you are on your own here! */
+@@ -360,11 +368,11 @@
+ qoztmp->leds[6] = 0x0;
+ qoztmp->leds[7] = 0x0;
+
+- if (qoztmp->type == 0xb552) {
++ if ((qoztmp->type == 0xb552) || (qoztmp->type == 0xb562)) {
+ qoztmp->stports = 8;
+- } else if (qoztmp->type == 0xb55b) {
++ } else if ((qoztmp->type == 0xb55b) || (qoztmp->type == 0xb56b)) {
+ qoztmp->stports = 8;
+- } else if (qoztmp->type == 0xb556) {
++ } else if ((qoztmp->type == 0xb556) || (qoztmp->type == 0xb566)) {
+ qoztmp->stports = 2;
+ } else if (qoztmp->type == 0xb557) {
+ qoztmp->stports = 2;
+@@ -373,7 +381,7 @@
+ }
+ qoztmp->ticks = 0;
+ qoztmp->clicks = 0;
+- if ((qoztmp->type == 0xb550) || (qoztmp->type == 0xb556)) {
++ if ((qoztmp->type == 0xb550) || (qoztmp->type == 0xb556) || (qoztmp->type == 0xb566)) {
+ printk(KERN_INFO "qozap: Starting hardware watchdog.\n");
+ qoztmp->wdp = 2;
+ } else {
+@@ -427,9 +435,9 @@
+ unsigned long flags;
+
+
+- if (qoztmp->type == 0xb552) {
++ if ((qoztmp->type == 0xb552) || (qoztmp->type == 0xb562)) {
+ offset = 24;
+- } else if (qoztmp->type == 0xb55b) {
++ } else if ((qoztmp->type == 0xb55b) || (qoztmp->type == 0xb56b)) {
+ offset = 24;
+ } else {
+ offset = 28;
+@@ -493,9 +501,9 @@
+ char offset = 0;
+ unsigned long flags;
+
+- if (qoztmp->type == 0xb552) {
++ if ((qoztmp->type == 0xb552) || (qoztmp->type == 0xb562)) {
+ offset = 24;
+- } else if (qoztmp->type == 0xb55b) {
++ } else if ((qoztmp->type == 0xb55b) || (qoztmp->type == 0xb56b)) {
+ offset = 24;
+ } else {
+ offset = 28;
+@@ -526,7 +534,7 @@
+ while ((oz1 != z1) && (oz2 != z2)) {
+ oz1 = z1;
+ oz2 = z2;
+- if ((qoztmp->type != 0xb552) && (qoztmp->type != 0xb55b)){
++ if ((qoztmp->type != 0xb552) && (qoztmp->type != 0xb55b) && (qoztmp->type != 0xb562) && (qoztmp->type != 0xb56b)){
+ z1 = qoz_inw(qoztmp,qoz_A_Z1) & 0x7ff;
+ z2 = qoz_inw(qoztmp,qoz_A_Z2) & 0x7ff;
+ } else {
+@@ -535,7 +543,7 @@
+ }
+ }
+
+- if ((qoztmp->type == 0xb552)|| (qoztmp->type == 0xb55b)) {
++ if ((qoztmp->type == 0xb552) || (qoztmp->type == 0xb55b) || (qoztmp->type == 0xb562) || (qoztmp->type == 0xb56b)) {
+ len = z1 - z2;
+ if (len < 0) {
+ len += qoz_DFIFO_SIZE8;
+@@ -944,9 +952,9 @@
+ if (debug > 1) {
+ printk(KERN_INFO "qozap: card %d R_BERT_STA = %#x\n", qoztmp->cardno, qoz_inb(qoztmp, qoz_R_BERT_STA) & 7);
+ }
+- if (qoztmp->type == 0xb552) {
++ if ((qoztmp->type == 0xb552) || (qoztmp->type == 0xb562)) {
+ offset = 24;
+- } else if (qoztmp->type == 0xb55b) {
++ } else if ((qoztmp->type == 0xb55b) || (qoztmp->type == 0xb56b)) {
+ offset = 24;
+ } else {
+ offset = 28;
+@@ -1131,7 +1139,7 @@
+ /* fifo irq */
+ spin_lock_irqsave(&(qoztmp->lock), flags);
+ irq_foview = qoz_inb(qoztmp,qoz_R_IRQ_OVIEW);
+- if ((qoztmp->type == 0xb552) || (qoztmp->type == 0xb55b)) {
++ if ((qoztmp->type == 0xb552) || (qoztmp->type == 0xb55b) || (qoztmp->type == 0xb562) || (qoztmp->type == 0xb56b)) {
+ if (irq_foview & 0x60) {
+ offset = 0;
+ fi = qoz_inb(qoztmp,qoz_R_IRQ_FIFO_BL6);
+@@ -1278,9 +1286,9 @@
+ // irqs off
+ qoz_outb(qoztmp,qoz_R_IRQ_CTRL, 0);
+
+- if (qoztmp->type == 0xb552) {
++ if ((qoztmp->type == 0xb552) || (qoztmp->type == 0xb562)) {
+ offset = 24;
+- } else if (qoztmp->type == 0xb55b) {
++ } else if ((qoztmp->type == 0xb55b) || (qoztmp->type == 0xb56b)) {
+ offset = 24;
+ } else {
+ offset = 28;
+@@ -1411,9 +1419,9 @@
+
+ spin_lock_irqsave(&qoztmp->lock,flags);
+ // turn off irqs for all fifos
+- if (qoztmp->type == 0xb552) {
++ if ((qoztmp->type == 0xb552) || (qoztmp->type == 0xb562)) {
+ offset = 24;
+- } else if (qoztmp->type == 0xb55b) {
++ } else if ((qoztmp->type == 0xb55b) || (qoztmp->type == 0xb56b)) {
+ offset = 24;
+ } else {
+ offset = 28;
+@@ -1642,7 +1650,7 @@
+ qoz_resetCard(qoztmp);
+
+
+- if ((tmp->subsystem_device==0xb520) && (pcidid == PCI_DEVICE_ID_CCD_M4)) {
++ if (((tmp->subsystem_device==0xb520) || (tmp->subsystem_device==0xb560)) && (pcidid == PCI_DEVICE_ID_CCD_M4)) {
+ // printk(KERN_INFO "MODES = %#x.\n",modes);
+ qoz_outb(qoztmp,qoz_R_GPIO_SEL,0x80 | 0x40);
+ qoz_outb(qoztmp,qoz_R_GPIO_EN1,0x00);
+@@ -1670,7 +1678,7 @@
+ }
+ }
+
+- } else if ((tmp->subsystem_device==0xb556) && (pcidid == PCI_DEVICE_ID_CCD_M4)) {
++ } else if (((tmp->subsystem_device==0xb556) || (tmp->subsystem_device==0xb566)) && (pcidid == PCI_DEVICE_ID_CCD_M4)) {
+ /* duoBRI */
+
+ /* gpi27 1 gpi23 2 */
+@@ -1686,7 +1694,7 @@
+ qoz_outw_io(qoztmp,0x0,0x0); */
+
+
+- } else if ((tmp->subsystem_device==0xb558) && (pcidid == PCI_DEVICE_ID_CCD_M4)) {
++ } else if (((tmp->subsystem_device==0xb558) || (tmp->subsystem_device==0xb568)) && (pcidid == PCI_DEVICE_ID_CCD_M4)) {
+ /* quadBRI minipCI */
+ qoz_outb(qoztmp,qoz_R_GPIO_SEL,0xF0);
+ qoz_outb(qoztmp,qoz_R_GPIO_EN0,0x00);
+@@ -1706,7 +1714,7 @@
+ }
+ // printk(KERN_INFO "DIPS = %#x CID= %#x\n",dips,cid);
+
+- } else if ((tmp->subsystem_device==0xb55b) && (pcidid == PCI_DEVICE_ID_CCD_M)){
++ } else if (((tmp->subsystem_device==0xb55b) || (tmp->subsystem_device==0xb56b)) && (pcidid == PCI_DEVICE_ID_CCD_M)){
+ qoz_outb(qoztmp,qoz_R_BRG_PCM_CFG,0x21);
+
+ dips = ~qoz_inb_io(qoztmp,0x4000);
+@@ -1730,7 +1738,7 @@
+ }
+
+ if (ports == -1) {
+- if ((tmp->subsystem_device==0xb520) && (pcidid == PCI_DEVICE_ID_CCD_M4)) {
++ if (((tmp->subsystem_device==0xb520) || (tmp->subsystem_device==0xb560)) && (pcidid == PCI_DEVICE_ID_CCD_M4)) {
+ modes = qoz_inb(qoztmp,qoz_R_GPI_IN3) >> 4;
+ } else if ((tmp->subsystem_device==0xb550) && (pcidid == PCI_DEVICE_ID_CCD_M4)) {
+ qoz_outb(qoztmp,qoz_R_GPIO_SEL,0xf0);
+@@ -1743,7 +1751,7 @@
+ printk(KERN_CRIT "gpi_in3 %#x \n", qoz_inb(qoztmp,qoz_R_GPI_IN3));
+ }
+ modes = qoz_inb(qoztmp,qoz_R_GPI_IN3) >> 4;
+- } else if ((tmp->subsystem_device==0xb558) && (pcidid == PCI_DEVICE_ID_CCD_M4)) {
++ } else if (((tmp->subsystem_device==0xb558) || (tmp->subsystem_device==0xb568)) && (pcidid == PCI_DEVICE_ID_CCD_M4)) {
+ qoz_outb(qoztmp,qoz_R_GPIO_SEL,0xf0);
+ qoz_outb(qoztmp,qoz_R_GPIO_EN0,0x00);
+ if (debug) {
+@@ -1754,7 +1762,7 @@
+ printk(KERN_CRIT "gpi_in3 %#x \n", qoz_inb(qoztmp,qoz_R_GPI_IN3));
+ }
+ modes = qoz_inb(qoztmp,qoz_R_GPI_IN3) >> 4;
+- } else if ((tmp->subsystem_device==0xb556) && (pcidid == PCI_DEVICE_ID_CCD_M4)) {
++ } else if (((tmp->subsystem_device==0xb556) || (tmp->subsystem_device==0xb566)) && (pcidid == PCI_DEVICE_ID_CCD_M4)) {
+ qoz_outb(qoztmp,qoz_R_GPIO_SEL,0xf0);
+ qoz_outb(qoztmp,qoz_R_GPIO_EN0,0x00);
+ if (debug) {
+@@ -1817,6 +1825,20 @@
+ qoztmp->irq, HZ, cid);
+ totalBRIs += 4;
+ break;
++ case 0xb560:
++ printk(KERN_INFO
++ "qozap: BeroNet BN4S0 card configured at io port %#x IRQ %d HZ %d CardID %d\n",
++ (u_int) qoztmp->ioport,
++ qoztmp->irq, HZ, cid);
++ totalBRIs += 4;
++ break;
++ case 0xb566:
++ printk(KERN_INFO
++ "qozap: BeroNet BN2S0 card configured at io port %#x IRQ %d HZ %d CardID %d\n",
++ (u_int) qoztmp->ioport,
++ qoztmp->irq, HZ, cid);
++ totalBRIs += 2;
++ break;
+ }
+ } else {
+ switch (tmp->subsystem_device) {
+@@ -1832,6 +1854,18 @@
+ (u_int) qoztmp->ioport,
+ qoztmp->irq, HZ);
+ break;
++ case 0xb562:
++ printk(KERN_INFO
++ "qozap: BeroNet BN8S0 card configured at io port %#x IRQ %d HZ %d\n",
++ (u_int) qoztmp->ioport,
++ qoztmp->irq, HZ);
++ break;
++ case 0xb56b:
++ printk(KERN_INFO
++ "qozap: BeroNet BN8S0 (+) card configured at io port %#x IRQ %d HZ %d\n",
++ (u_int) qoztmp->ioport,
++ qoztmp->irq, HZ);
++ break;
+ default:
+ printk(KERN_INFO
+ "qozap: wtf\n");
Propchange: zaptel/trunk/debian/patches/beronet.dpatch
------------------------------------------------------------------------------
svn:executable = *
More information about the Pkg-voip-commits
mailing list