[svn-commits] sruffell: linux/trunk r7008 - /linux/trunk/drivers/dahdi/wcfxo.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Fri Aug 14 10:47:45 CDT 2009


Author: sruffell
Date: Fri Aug 14 10:47:39 2009
New Revision: 7008

URL: http://svn.asterisk.org/svn-view/dahdi?view=rev&rev=7008
Log:
wcfxo: Reset the DAA on module initialization.

The X100p and clones will sometimes work and sometimes not depending on wether
the DAA powers up in running state- this seems to be related to the power
supply. This problem is caused by the driver not reseting the DAA and may be
the source of a great many intermittent problems with this card.

(closes issue #14232)
Reported by: tallen8840
Patch by: tallen8840
Tested by: explidous, Flavio

Modified:
    linux/trunk/drivers/dahdi/wcfxo.c

Modified: linux/trunk/drivers/dahdi/wcfxo.c
URL: http://svn.asterisk.org/svn-view/dahdi/linux/trunk/drivers/dahdi/wcfxo.c?view=diff&rev=7008&r1=7007&r2=7008
==============================================================================
--- linux/trunk/drivers/dahdi/wcfxo.c (original)
+++ linux/trunk/drivers/dahdi/wcfxo.c Fri Aug 14 10:47:39 2009
@@ -674,6 +674,16 @@
 	/* Hardware stuff */
 	/* Reset PCI Interface chip and registers */
 	outb(0x0e, wc->ioaddr + WC_CNTL);
+
+	/* Set all to outputs except AUX 4, which is an input */
+	outb(0xef, wc->ioaddr + WC_AUXC);
+
+	/* Reset the DAA (DAA uses AUX5 for reset) */
+	outb(0x00, wc->ioaddr + WC_AUXD);
+	set_current_state(TASK_INTERRUPTIBLE);
+	schedule_timeout(1 + HZ / 800);
+
+	/* Set hook state to on hook & un-reset the DAA */
 	if (wc->flags & FLAG_RESET_ON_AUX5) {
 		/* Set hook state to on hook for when we switch.
 		   Make sure reset is high */
@@ -682,8 +692,6 @@
 		/* Set hook state to on hook for when we switch */
 		outb(0x24, wc->ioaddr + WC_AUXD);
 	}
-	/* Set all to outputs except AUX 4, which is an input */
-	outb(0xef, wc->ioaddr + WC_AUXC);
 
 	/* Back to normal, with automatic DMA wrap around */
 	outb(0x01, wc->ioaddr + WC_CNTL);




More information about the svn-commits mailing list