[svn-commits] sruffell: linux/trunk r9555 - /linux/trunk/drivers/dahdi/wcb4xxp/base.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Mon Jan 3 13:07:12 UTC 2011


Author: sruffell
Date: Mon Jan  3 07:06:54 2011
New Revision: 9555

URL: http://svnview.digium.com/svn/dahdi?view=rev&rev=9555
Log:
wcb4xxp: HDLC packets do not pass over D-channel.

dahdi/wcb4xxp driver used with Digium Wildcard B410 quad-BRI PCI card
unable to communicate with another ISDN device (ISDN phone, another port
of B410). It appears that B-channels are capable to transport data, but
D-channel is not.

Debug output added into the driver shows that packets are transmitted to
the D-channel, but no packets are received. Further investigation shows
that no interrupts received from Rx FIFO associated with D-channel,
although packets are delivered to the FIFO. I've found that problem is
in improper usage of chan->chanpos while indexing the fifo index
(bspan->fifos): chanpos starts from 1 and fifos starts from 0.
Therefore, garbage read instead of fifo number.

(closes issue #14834)
Reported by: vvv
Patches:
      dahdi-linux-complete-2.2.0-rc1.patch uploaded by vvv (license 741)

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

Modified:
    linux/trunk/drivers/dahdi/wcb4xxp/base.c

Modified: linux/trunk/drivers/dahdi/wcb4xxp/base.c
URL: http://svnview.digium.com/svn/dahdi/linux/trunk/drivers/dahdi/wcb4xxp/base.c?view=diff&rev=9555&r1=9554&r2=9555
==============================================================================
--- linux/trunk/drivers/dahdi/wcb4xxp/base.c (original)
+++ linux/trunk/drivers/dahdi/wcb4xxp/base.c Mon Jan  3 07:06:54 2011
@@ -1902,8 +1902,10 @@
 		for (i=0; i < size; i++)
 			printk("%02x%c", buf[i], (i < (size - 1)) ? ' ' : '\n');
 
-		if (size && res != 0)
-			pr_info("Transmitted frame %d on span %d\n", bspan->frames_out - 1, bspan->port);
+		if (size && res != 0) {
+			pr_info("Transmitted frame %d on span %d\n",
+				bspan->frames_out - 1, bspan->port + 1);
+		}
 	}
 
 	return(res == 0);
@@ -2403,7 +2405,7 @@
 			 chan->name, chan->channo, chan->chanpos);
 	}
 
-	hfc_reset_fifo_pair(b4, bspan->fifos[chan->chanpos], 0, 0);
+	hfc_reset_fifo_pair(b4, bspan->fifos[chan->chanpos - 1], 0, 0);
 	return 0;
 }
 
@@ -2418,7 +2420,7 @@
 			 chan->name, chan->channo, chan->chanpos);
 	}
 
-	hfc_reset_fifo_pair(b4, bspan->fifos[chan->chanpos], 1, 1);
+	hfc_reset_fifo_pair(b4, bspan->fifos[chan->chanpos - 1], 1, 1);
 	return 0;
 }
 




More information about the svn-commits mailing list