[svn-commits] sruffell: branch linux/2.4 r10113 - /linux/branches/2.4/drivers/dahdi/

SVN commits to the Digium repositories svn-commits at lists.digium.com
Thu Aug 11 14:54:52 CDT 2011


Author: sruffell
Date: Thu Aug 11 14:54:48 2011
New Revision: 10113

URL: http://svnview.digium.com/svn/dahdi?view=rev&rev=10113
Log:
dahdi_dynamic: Call dahdi_receive in rx packet handler.

Currently dahdi_receive is called on all channels in the context of the
master dynamic span. If one span (not the master) receive two packets
before the master span received a packet, the older packet on the
dynamic span would end up lost because the "readchunk" for the
channels would be overwritten by the new packet. DAHLIN-245

Signed-off-by: Wagner Gegler <wagner at aligera.com.br> (License #6268)
Changed dahdi_ec_chunk to dahdi_ec_span.
Signed-off-by: Shaun Ruffell <sruffell at digium.com>

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

Conflicts:

	drivers/dahdi/dahdi_dynamic.c

Modified:
    linux/branches/2.4/drivers/dahdi/dahdi_dynamic.c

Modified: linux/branches/2.4/drivers/dahdi/dahdi_dynamic.c
URL: http://svnview.digium.com/svn/dahdi/linux/branches/2.4/drivers/dahdi/dahdi_dynamic.c?view=diff&rev=10113&r1=10112&r2=10113
==============================================================================
--- linux/branches/2.4/drivers/dahdi/dahdi_dynamic.c (original)
+++ linux/branches/2.4/drivers/dahdi/dahdi_dynamic.c Thu Aug 11 14:54:48 2011
@@ -222,16 +222,10 @@
 {
 	struct dahdi_dynamic *z;
 	struct dahdi_dynamic_driver *drv;
-	int y;
 
 	rcu_read_lock();
 	list_for_each_entry_rcu(z, &dspan_list, list) {
 		if (!z->dead) {
-			for (y=0;y<z->span.channels;y++) {
-				/* Echo cancel double buffered data */
-				dahdi_ec_chunk(z->span.chans[y], z->span.chans[y]->readchunk, z->span.chans[y]->writechunk);
-			}
-			dahdi_receive(&z->span);
 			dahdi_transmit(&z->span);
 			/* Handle all transmissions now */
 			ztd_sendmessage(z);
@@ -396,6 +390,9 @@
 	/* note if we had a missing packet */
 	if (unlikely(rxpos != rxcnt))
 		printk(KERN_NOTICE "Span %s: Expected seq no %d, but received %d instead\n", span->name, rxcnt, rxpos);
+
+	dahdi_ec_span(span);
+	dahdi_receive(span);
 
 	/* If this is our master span, then run everything */
 	if (master)




More information about the svn-commits mailing list