Subject: Re: esp/fas
To: None <and@genesyslab.com, eeh@netbsd.org>
From: None <eeh@netbsd.org>
List: port-sparc64
Date: 01/30/2001 04:37:19
	It's the same DVMA problem. The very new kernel (as of today)
	doesn't cause dma errors, works for some time(longer then before), but
	ends up in ddb with:

	iommu_strbuf_flush: flush timeout 0x100000000 at 0x3cbbbc8

The IOMMU's streaming buffer is flushed by poking a 
register with a value and then waiting until the 
IOMMU has written something to a particular memory 
location.  This should occur within 1/2 second or
it's considered a timeout.  

There arre a couple of possible reasons for the
timeout:

1) The streaming buffer is not enabled.  If you 
have coherent mappings the streaming buffer is not
used.

2) Interrupt latency/clock problems.  If the clock
is running too fast you may not wait long enough.

3) There is some discrpency bettween the varible
being waited on and the address changed by the
IOMMU.

In any case, this should not be a fatal condition,
and you can probably work around it by disablinng
the streaming cache entirely or using only COHERENT
mappings.

Altought, looking at the code:

#ifdef DIAGNOSTIC
	if (!is->is_flush) {
		printf("iommu_strbuf_flush: flush timeout %p at %p\n",
		    (void *)(u_long)is->is_flush, 
		    (void *)(u_long)is->is_flushpa); /* panic? */

if is->is_flush really is 0x100000000, either the code generation
is broken, or the value was set between the test and the printf ()
call.  Maybe you should just increase the timeout a bit.

Eduardo