Commit 59512900 authored by Andi Kleen's avatar Andi Kleen Committed by Robert Richter

oprofile: discover counters for op ppro too

Discover number of counters for all family 6 models even when not
in arch perfmon mode.
Signed-off-by: default avatarAndi Kleen <ak@linux.intel.com>
Signed-off-by: default avatarRobert Richter <robert.richter@amd.com>
parent b9917028
...@@ -200,9 +200,9 @@ static void ppro_shutdown(struct op_msrs const * const msrs) ...@@ -200,9 +200,9 @@ static void ppro_shutdown(struct op_msrs const * const msrs)
} }
struct op_x86_model_spec const op_ppro_spec = { struct op_x86_model_spec op_ppro_spec = {
.num_counters = 2, .num_counters = 2, /* can be overriden */
.num_controls = 2, .num_controls = 2, /* dito */
.fill_in_addresses = &ppro_fill_in_addresses, .fill_in_addresses = &ppro_fill_in_addresses,
.setup_ctrs = &ppro_setup_ctrs, .setup_ctrs = &ppro_setup_ctrs,
.check_ctrs = &ppro_check_ctrs, .check_ctrs = &ppro_check_ctrs,
...@@ -238,6 +238,8 @@ void arch_perfmon_setup_counters(void) ...@@ -238,6 +238,8 @@ void arch_perfmon_setup_counters(void)
op_arch_perfmon_spec.num_counters = num_counters; op_arch_perfmon_spec.num_counters = num_counters;
op_arch_perfmon_spec.num_controls = num_counters; op_arch_perfmon_spec.num_controls = num_counters;
op_ppro_spec.num_counters = num_counters;
op_ppro_spec.num_controls = num_counters;
} }
struct op_x86_model_spec op_arch_perfmon_spec = { struct op_x86_model_spec op_arch_perfmon_spec = {
......
...@@ -45,7 +45,7 @@ struct op_x86_model_spec { ...@@ -45,7 +45,7 @@ struct op_x86_model_spec {
void (*shutdown)(struct op_msrs const * const msrs); void (*shutdown)(struct op_msrs const * const msrs);
}; };
extern struct op_x86_model_spec const op_ppro_spec; extern struct op_x86_model_spec op_ppro_spec;
extern struct op_x86_model_spec const op_p4_spec; extern struct op_x86_model_spec const op_p4_spec;
extern struct op_x86_model_spec const op_p4_ht2_spec; extern struct op_x86_model_spec const op_p4_ht2_spec;
extern struct op_x86_model_spec const op_amd_spec; extern struct op_x86_model_spec const op_amd_spec;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment