Received: from sfbaymail1sca.SFBay.Sun.COM (sfbaymail1sca [129.145.154.35])
	by datsun.SFBay.Sun.COM (8.12.10+Sun/8.12.2) with ESMTP id i9S69kWT025705
	for <shannon-record@datsun.SFBay.Sun.COM>; Wed, 27 Oct 2004 23:09:46 -0700 (PDT)
Received: from nissan.sfbay.sun.com (vpn-129-150-16-112.SFBay.Sun.COM [129.150.16.112])
	by sfbaymail1sca.SFBay.Sun.COM (8.12.10+Sun/8.12.10/ENSMAIL,v2.2) with ESMTP id i9S6BWEG007274;
	Wed, 27 Oct 2004 23:11:32 -0700 (PDT)
Received: from sun.com (micron [192.168.1.5])
	by nissan.sfbay.sun.com (8.12.10+Sun/8.12.5) with ESMTP id i9S6A2GF003014;
	Wed, 27 Oct 2004 23:10:02 -0700 (PDT)
Message-ID: <41808DB9.9030900@sun.com>
Date: Wed, 27 Oct 2004 23:12:09 -0700
From: Bill Shannon <bill.shannon@sun.com>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040510
X-Accept-Language: en-us, en
MIME-Version: 1.0
To: keith@tungstengraphics.com, anholt@FreeBSD.org
Subject: Re: r128 driver problems
References: <41804180.6070602@sun.com>
In-Reply-To: <41804180.6070602@sun.com>
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit

Ok, I think I've now proven that my ATI Rage 128 device is generating
interrupts even after the r128 driver disables interrupts.

In r128_driver_irq_uninstall, after it writes to the device to
disable interrupts, I set a global variable that says interrupts
are disabled.  I then use vblank_wait to wait for the next
vblank interrupt.  If interrupts were really disabled, I would
expect vblank_wait to return indicating that the timeout expired.
It doesn't, it returns success.

In r128_dma_service, if I get an interrupt while the global
"interrupts are disabled" flag is set, I increment a counter.
After vblank_wait returns in r128_driver_irq_uninstall, I
check the count.  It indicates that an interrupt was received
after interrupts were disabled.

To me, that looks like proof that there's something wrong here.
Maybe the hardware is broken, or maybe it's just not working
the way the driver expects.  Or maybe the driver is not doing
the right thing to really disable interrupts.

At this point I need some help.  Are either of you the right
person to help?  If not, can you point me to someone else who
might be able to help?

Thanks much!

	Bill Shannon
