<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">My apologies, in my exuberance I initially sent this to the two programmers at the top of the source listing having read all the code except the comment telling me not to do what I did.&nbsp;<div><br></div><div>After spending a week in a lab trying to track down what I thought was a hardware bug I have found that the driver&nbsp;fails&nbsp;to reset the DAA.&nbsp;Apparently&nbsp;the writer assumed, as did I&nbsp;until&nbsp;I reverse engineered the card, that bit 0 in WC_CNTL would reset the PCI interface as well as the DAA; however, for reasons I'm unclear on, the hardware designers wired the DAA's reset to AUX5; therefore, it is necessary to take AUX5 low for a few ms and then high to reset the DAA.&nbsp;</div><div><br></div><div>Many people have varying levels of&nbsp;success with this card. This seems to be related to their power supplies. I have observed that some power supplies seem to have a higher&nbsp;likelihood&nbsp;of making the DAA come up in a running state (doesn't need a reset).</div><div><br></div><div>Anyway, here's the patch- hope I did it right, never made a patch before. Those of you trying this please keep an eye out for a spurious NMI the first time the driver loads. I saw it once or twice. Not sure what it is- it doesn't&nbsp;reoccur&nbsp;or crash my machine.</div><div><br></div><div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">--- wcfxo.c<span class="Apple-tab-span" style="white-space:pre">        </span>2008-08-13 20:58:36.000000000 -0400</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">+++ wcfxoNew.c<span class="Apple-tab-span" style="white-space:pre">        </span>2009-01-11 11:24:51.000000000 -0500</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">@@ -696,6 +696,16 @@</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">&nbsp;<span class="Apple-tab-span" style="white-space:pre">        </span>/* Hardware stuff */</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">&nbsp;<span class="Apple-tab-span" style="white-space:pre">        </span>/* Reset PCI Interface chip and registers */</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">&nbsp;<span class="Apple-tab-span" style="white-space:pre">        </span>outb(0x0e, wc->ioaddr + WC_CNTL);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">+<span class="Apple-tab-span" style="white-space:pre">        </span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">+<span class="Apple-tab-span" style="white-space:pre">        </span>/* Set all to outputs except AUX 4, which is an input */</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">+<span class="Apple-tab-span" style="white-space:pre">        </span>outb(0xef, wc->ioaddr + WC_AUXC);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">+<span class="Apple-tab-span" style="white-space:pre">        </span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">+<span class="Apple-tab-span" style="white-space:pre">        </span>/* Reset the DAA (DAA uses AUX5 for reset) */</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">+<span class="Apple-tab-span" style="white-space:pre">        </span>outb(0x00, wc->ioaddr + WC_AUXD);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">+<span class="Apple-tab-span" style="white-space:pre">        </span>set_current_state(TASK_INTERRUPTIBLE);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">+<span class="Apple-tab-span" style="white-space:pre">        </span>schedule_timeout(1 + HZ / 800);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">+<span class="Apple-tab-span" style="white-space:pre">        </span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">+<span class="Apple-tab-span" style="white-space:pre">        </span>/* Set hook state to on hook &amp; un-reset the DAA */&nbsp;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">&nbsp;<span class="Apple-tab-span" style="white-space:pre">        </span>if (wc->flags &amp; FLAG_RESET_ON_AUX5) {</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">&nbsp;<span class="Apple-tab-span" style="white-space:pre">                </span>/* Set hook state to on hook for when we switch.</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">&nbsp;<span class="Apple-tab-span" style="white-space:pre">                </span> &nbsp; Make sure reset is high */</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">@@ -704,9 +714,7 @@</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">&nbsp;<span class="Apple-tab-span" style="white-space:pre">                </span>/* Set hook state to on hook for when we switch */</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">&nbsp;<span class="Apple-tab-span" style="white-space:pre">                </span>outb(0x24, wc->ioaddr + WC_AUXD);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">&nbsp;<span class="Apple-tab-span" style="white-space:pre">        </span>}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">-<span class="Apple-tab-span" style="white-space:pre">        </span>/* Set all to outputs except AUX 4, which is an input */</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">-<span class="Apple-tab-span" style="white-space:pre">        </span>outb(0xef, wc->ioaddr + WC_AUXC);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">-</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">+<span class="Apple-tab-span" style="white-space:pre">        </span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">&nbsp;<span class="Apple-tab-span" style="white-space:pre">        </span>/* Back to normal, with automatic DMA wrap around */</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Monaco; ">&nbsp;<span class="Apple-tab-span" style="white-space:pre">        </span>outb(0x01, wc->ioaddr + WC_CNTL);</div></div></body></html>