Clear done_head in the HCCA *before* acknoledging the interrupt.

Driver lost some completed transfers under heavy loads.
This commit is contained in:
minoura 2002-05-26 03:10:02 +00:00
parent 66f94c684f
commit 78d97e78f0
1 changed files with 3 additions and 3 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: ohci.c,v 1.123 2002/05/19 06:24:31 augustss Exp $ */
/* $NetBSD: ohci.c,v 1.124 2002/05/26 03:10:02 minoura Exp $ */
/* $FreeBSD: src/sys/dev/usb/ohci.c,v 1.22 1999/11/17 22:33:40 n_hibma Exp $ */
/*
@ -46,7 +46,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: ohci.c,v 1.123 2002/05/19 06:24:31 augustss Exp $");
__KERNEL_RCSID(0, "$NetBSD: ohci.c,v 1.124 2002/05/26 03:10:02 minoura Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -1115,6 +1115,7 @@ ohci_intr1(ohci_softc_t *sc)
intrs = OHCI_WDH;
if (done & OHCI_DONE_INTRS)
intrs |= OREAD4(sc, OHCI_INTERRUPT_STATUS);
sc->sc_hcca->hcca_done_head = 0;
} else
intrs = OREAD4(sc, OHCI_INTERRUPT_STATUS);
@ -1145,7 +1146,6 @@ ohci_intr1(ohci_softc_t *sc)
}
if (eintrs & OHCI_WDH) {
ohci_add_done(sc, done &~ OHCI_DONE_INTRS);
sc->sc_hcca->hcca_done_head = 0;
usb_schedsoftintr(&sc->sc_bus);
eintrs &= ~OHCI_WDH;
}