x86, ds: support Core i7
PATCH 21/21 x86, ds: support Core i7
Add debug store support for Core i7.
Core i7 adds a reset value for each performance counter and a new PEBS record format.
---
--- arch/x86/include/asm/ds.h | 10 ++++++++-- arch/x86/kernel/ds.c | 24 ++++++++++++++++++++++++ 2 files changed, 32 insertions(+), 2 deletions(-)
arch/x86/include/asm/ds.h +9 -3
@@ -234,8 +234,12 @@ struct bts_trace {struct pebs_trace {struct ds_trace ds; -/* the PEBS reset value */ -unsigned long long reset_value; +/* the number of valid counters in the below array */ +unsigned int counters; + +#define MAX_PEBS_COUNTERS 4 +/* the counter reset value */ +unsigned long long counter_reset[MAX_PEBS_COUNTERS ]; };
@@ -270,9 +274,11 @@ extern int ds_reset_pebs(struct pebs_tra* Returns 0 on success; -Eerrno on error * * tracer: the tracer handle returned from ds_request_pebs() +* counter: the index of the counter * value: the new counter reset value */ -extern int ds_set_pebs_reset (struct pebs_tracer *tracer,u64 value); +extern int ds_set_pebs_reset (struct pebs_tracer *tracer, +unsigned int counter,u64 value);/* * Initialization
arch/x86/kernel/ds.c +62 -7
138 lines not on this page · raw message
---------------------------------------------------------------------
Intel GmbH
Dornacher Strasse 1
85622 Feldkirchen/Muenchen Germany
Sitz der Gesellschaft: Feldkirchen bei Muenchen
Geschaeftsfuehrer: Douglas Lusk, Peter Gleissner, Hannes Schwaderer
Registergericht: Muenchen HRB 47456 Ust.-IdNr.
VAT Registration No.: DE129385895
Citibank Frankfurt (BLZ 502 109 00) 600119052
This e-mail and any attachments may contain confidential material for the sole use of the intended recipient(s). Any review or distribution by others is strictly prohibited. If you are not the intended recipient, please contact the sender and delete all copies.