summaryrefslogtreecommitdiffstats
path: root/arch/x86/oprofile/op_model_athlon.c
diff options
context:
space:
mode:
authorRobert Richter <robert.richter@amd.com>2008-07-22 21:08:48 +0200
committerIngo Molnar <mingo@elte.hu>2008-07-26 11:48:01 +0200
commitadf5ec0bca553b763a6b9baed2677a4c7470025b (patch)
treec3009400fcdd1d0a27ab96e8d9ed6a88535307d4 /arch/x86/oprofile/op_model_athlon.c
parentoprofile: Add support for AMD Family 11h (diff)
downloadlinux-adf5ec0bca553b763a6b9baed2677a4c7470025b.tar.xz
linux-adf5ec0bca553b763a6b9baed2677a4c7470025b.zip
x86/oprofile: introduce model specific init/exit functions
This patch implements model specific OProfile init/exit functions for x86 CPUs. Though there is more rework needed at the initialization code, this new introduced functions allow it to keep model specific code in the corresponding op_model_*.c files. The function interface is the same as for oprofile_arch_init/exit(). Signed-off-by: Robert Richter <robert.richter@amd.com> Cc: oprofile-list <oprofile-list@lists.sourceforge.net> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/oprofile/op_model_athlon.c')
-rw-r--r--arch/x86/oprofile/op_model_athlon.c18
1 files changed, 15 insertions, 3 deletions
diff --git a/arch/x86/oprofile/op_model_athlon.c b/arch/x86/oprofile/op_model_athlon.c
index 3d534879a9dc..dd8b1dcd163b 100644
--- a/arch/x86/oprofile/op_model_athlon.c
+++ b/arch/x86/oprofile/op_model_athlon.c
@@ -1,14 +1,15 @@
/*
- * @file op_model_athlon.h
+ * @file op_model_athlon.c
* athlon / K7 / K8 / Family 10h model-specific MSR operations
*
- * @remark Copyright 2002 OProfile authors
+ * @remark Copyright 2002-2008 OProfile authors
* @remark Read the file COPYING
*
* @author John Levon
* @author Philippe Elie
* @author Graydon Hoare
- */
+ * @author Robert Richter <robert.richter@amd.com>
+*/
#include <linux/oprofile.h>
#include <asm/ptrace.h>
@@ -178,7 +179,18 @@ static void athlon_shutdown(struct op_msrs const * const msrs)
}
}
+static int op_amd_init(struct oprofile_operations *ops)
+{
+ return 0;
+}
+
+static void op_amd_exit(void)
+{
+}
+
struct op_x86_model_spec const op_athlon_spec = {
+ .init = op_amd_init,
+ .exit = op_amd_exit,
.num_counters = NUM_COUNTERS,
.num_controls = NUM_CONTROLS,
.fill_in_addresses = &athlon_fill_in_addresses,