From 51612e5ac3ddfb2bb172c58f2dfff9631093b69c Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Tue, 12 Jun 2007 16:09:54 -0700 Subject: [PATCH] On hang, dump up to the head pointer, not just up to the tail. --- src/i830_debug.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/i830_debug.c b/src/i830_debug.c index 19eb17a3..93549585 100644 --- a/src/i830_debug.c +++ b/src/i830_debug.c @@ -666,7 +666,8 @@ i830_dump_ring(ScrnInfoPtr pScrn) virt = pI830->LpRing->virtual_start; ErrorF ("Ring at virtual 0x%x head 0x%x tail 0x%x count %d\n", (unsigned int) virt, head, tail, (((tail + mask + 1) - head) & mask) >> 2); - for (ring = (head - 128) & mask; ring != tail; ring = (ring + 4) & mask) + for (ring = (head - 128) & mask; ring != ((head + 4) & mask); + ring = (ring + 4) & mask) { ErrorF ("\t%08x: %08x\n", ring, *(volatile unsigned int *) (virt + ring)); }