]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
x86, bts: correctly report invalid bts records
authorMarkus Metzger <markus.t.metzger@intel.com>
Tue, 16 Dec 2008 14:53:11 +0000 (15:53 +0100)
committerIngo Molnar <mingo@elte.hu>
Tue, 16 Dec 2008 17:28:37 +0000 (18:28 +0100)
Impact: change the reporting of empty BTS records

Correctly report a cleared BTS record as invalid. Used to be reported
as branch from 0 to 0.

Signed-off-by: Markus Metzger <markus.t.metzger@intel.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/kernel/ds.c

index 0dc795951d73f0246ee96479eb6464ad4e585cf4..98d271e60e086359d2042af7c4177cc817983e39 100644 (file)
@@ -484,6 +484,9 @@ static int bts_read(struct bts_tracer *tracer, const void *at,
                out->qualifier = bts_branch;
                out->variant.lbr.from = bts_get(at, bts_from);
                out->variant.lbr.to   = bts_get(at, bts_to);
+
+               if (!out->variant.lbr.from && !out->variant.lbr.to)
+                       out->qualifier = bts_invalid;
        }
 
        return ds_cfg.sizeof_rec[ds_bts];