tools/decode: don't move around the display register section
authorDaniel Vetter <daniel.vetter@ffwll.ch>
Tue, 18 Oct 2011 13:54:31 +0000 (15:54 +0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Tue, 18 Oct 2011 13:54:31 +0000 (15:54 +0200)
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
tools/intel_error_decode.c

index 2782bbb..8585425 100644 (file)
@@ -315,6 +315,16 @@ read_data_file (FILE *file)
        if (matched != 2) {
            unsigned int reg;
 
+           /* display reg section is after the ringbuffers, don't mix them */
+           if (count) {
+                   printf("%s (%s) at 0x%08x:\n",
+                          buffer_type[is_batch],
+                          ring_name,
+                          gtt_offset);
+                   intel_decode (data, count, gtt_offset, devid, 0);
+                   count = 0;
+           }
+
            printf("%s", line);
 
            matched = sscanf (line, "PCI ID: 0x%04x\n", &reg);