Subject: Re: Fixed esp driver bug at workaround.[Re: Kernel asm compile errors]
To: Takeshi Shibagaki <ie9t-sbgk@asahi-net.or.jp>
From: Allen Briggs <briggs@wasabisystems.com>
List: port-mac68k
Date: 02/02/2001 10:21:42
> I fixed a bug of esp driver, and attach a workaround patch in this mail.

What does this fix?  Dropping the block size down to 8k from 64k
may simply be hiding the real problem.  Do you have the following
code starting at line 539 in esp.c ?

        if ((sc->sc_espstat & NCRSTAT_TC) == 0) {
                if (esc->sc_datain == 0) {
                        resid = NCR_READ_REG(sc, NCR_FFLAG) & 0x1f;
#if DEBUG
                        if (mac68k_esp_debug) {
                                printf("Write FIFO residual %d bytes\n", resid);
                        }
#endif
                }
                resid += NCR_READ_REG(sc, NCR_TCL);
                resid += NCR_READ_REG(sc, NCR_TCM) << 8;
                if (resid == 0)
                        resid = 65536;
        }

Thank you for looking at this!

-allen

-- 
 Allen Briggs                     briggs@wasabisystems.com
 http://www.wasabisystems.com/    Quality NetBSD CDs, Sales, Support, Service