When flipping the first entry in the qinfifo with the "next queued SCB",

we must also inform the card of this change.  Otherwise the sequencer
will traverse a corrupt list of SCBS.  The side effects of this problem
were unknown SCBs completing in the qoutfifo or worse yet, panics due
to sequencer interrupts that referenced what, to the kernel, were invalid
SCB ids.
This commit is contained in:
Justin T. Gibbs 2001-01-23 22:17:03 +00:00
parent 4a08af58fe
commit 98ba52eadc
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=71473

View File

@ -28,7 +28,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
* $Id: //depot/src/aic7xxx/aic7xxx.c#24 $
* $Id: //depot/src/aic7xxx/aic7xxx.c#26 $
*
* $FreeBSD$
*/
@ -4879,6 +4879,9 @@ ahc_search_qinfifo(struct ahc_softc *ahc, int target, char channel,
scb->hscb->next = next;
ahc->qinfifo[qinstart] = scb->hscb->tag;
/* Tell the card about the new head of the qinfifo. */
ahc_outb(ahc, NEXT_QUEUED_SCB, scb->hscb->tag);
/* Fixup the tail "next" pointer. */
qintail = ahc->qinfifonext - 1;
scb = ahc_lookup_scb(ahc, ahc->qinfifo[qintail]);