提交 7e4e0bd5 编写于 作者: R Robert Richter

oprofile: introduce module_param oprofile.cpu_type

This patch removes module_param oprofile.force_arch_perfmon and
introduces oprofile.cpu_type=archperfmon instead. This new parameter
can be reused for other models and architectures.

Currently only archperfmon is supported.

Cc: Andi Kleen <ak@linux.intel.com>
Signed-off-by: NRobert Richter <robert.richter@amd.com>
上级 6adf406f
...@@ -1650,11 +1650,13 @@ and is between 256 and 4096 characters. It is defined in the file ...@@ -1650,11 +1650,13 @@ and is between 256 and 4096 characters. It is defined in the file
oprofile.timer= [HW] oprofile.timer= [HW]
Use timer interrupt instead of performance counters Use timer interrupt instead of performance counters
oprofile.force_arch_perfmon=1 [X86] oprofile.cpu_type= Force an oprofile cpu type
Force use of architectural perfmon instead of This might be useful if you have an older oprofile
the CPU specific event set. userland or if you want common events.
This might be useful if you have older oprofile Format: { archperfmon }
userland or if you want common events over Intel CPUs. archperfmon: [X86] Force use of architectural
perfmon on Intel CPUs instead of the
CPU specific event set.
osst= [HW,SCSI] SCSI Tape Driver osst= [HW,SCSI] SCSI Tape Driver
Format: <buffer_size>,<write_threshold> Format: <buffer_size>,<write_threshold>
......
...@@ -386,8 +386,17 @@ static int __init p4_init(char **cpu_type) ...@@ -386,8 +386,17 @@ static int __init p4_init(char **cpu_type)
return 0; return 0;
} }
int force_arch_perfmon; static int force_arch_perfmon;
module_param(force_arch_perfmon, int, 0); static int force_cpu_type(const char *str, struct kernel_param *kp)
{
if (!strcmp(str, "archperfmon")) {
force_arch_perfmon = 1;
printk(KERN_INFO "oprofile: forcing architectural perfmon\n");
}
return 0;
}
module_param_call(cpu_type, force_cpu_type, NULL, NULL, 0);
static int __init ppro_init(char **cpu_type) static int __init ppro_init(char **cpu_type)
{ {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册