Date: Sun, 30 Apr 2006 06:50:55 +0800 From: David Xu <davidxu@freebsd.org> To: John Baldwin <jhb@freebsd.org> Cc: cvs-src@freebsd.org, src-committers@freebsd.org, cvs-all@freebsd.org Subject: Re: cvs commit: src/sys/dev/nve if_nve.c Message-ID: <200604300650.55256.davidxu@freebsd.org> In-Reply-To: <200604282008.k3SK8Gqe045067@repoman.freebsd.org> References: <200604282008.k3SK8Gqe045067@repoman.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Saturday 29 April 2006 04:08, John Baldwin wrote: > jhb 2006-04-28 20:08:16 UTC > > FreeBSD src repository > > Modified files: > sys/dev/nve if_nve.c > Log: > The nvidia binary blob sometimes defers tx completion notification to the > OS dependent layer. Thus, the watchdog timer can go off when the tx > engine is working fine but the OS dependent layer just hasn't been called > to cleanup finished tx transactions. To workaround this, when the > watchdog fires, poke the binary blob to force it to flush any pending tx > completions. If this drops the pending tx count to zero then just return > without logging a message or resetting the chip. > > This reportedly fixes the 'device timeout()' errors with at least several > NF4 nve(4) parts. > > Submitted by: Nathan Alexander Whitehorn <nathanw@uchicago.edu> (code) > Submitted by: dg (inspiration for comment and explanation) > MFC after: 1 week > > Revision Changes Path > 1.21 +19 -1 src/sys/dev/nve/if_nve.c no change here, I still got the same timeout error, it is NForce 3 Ultra, when watchdog was triggered, the machine froze. I turned on 'force async mode', than the freezing went away, though timeout still occured. Only after changing TX_RING_SIZE to 251, the timeout problem completey went away even under heavy load, I got the number 251 from pfnQueryWriteSlots(), I think the default TX_RING_SIZE is too small for me. Index: if_nve.c =================================================================== RCS file: /home/ncvs/src/sys/dev/nve/if_nve.c,v retrieving revision 1.21 diff -u -r1.21 if_nve.c --- if_nve.c 28 Apr 2006 20:08:16 -0000 1.21 +++ if_nve.c 29 Apr 2006 22:36:58 -0000 @@ -650,7 +650,7 @@ 0, /* force speed */ 0, /* force full duplex */ 0, /* force mode */ - 0, /* force async mode */ + 1, /* force async mode */ &sc->linkup); if (error) { Index: if_nvereg.h =================================================================== RCS file: /home/ncvs/src/sys/dev/nve/if_nvereg.h,v retrieving revision 1.7 diff -u -r1.7 if_nvereg.h --- if_nvereg.h 7 Dec 2005 17:38:03 -0000 1.7 +++ if_nvereg.h 29 Apr 2006 22:36:58 -0000 @@ -51,7 +51,7 @@ #define NV_RID 0x10 -#define TX_RING_SIZE 64 +#define TX_RING_SIZE 251 #define RX_RING_SIZE 64 #define NV_MAX_FRAGS 32 // match adapter.h:ADAPTER_WRITE_DATA.sElement[]
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200604300650.55256.davidxu>