Commit f77be5bb authored by Richard Henderson's avatar Richard Henderson Committed by Richard Henderson

[OPROF] Display banner message on startup.

parent 544786eb
...@@ -151,29 +151,40 @@ static struct oprofile_operations oprof_axp_ops = { ...@@ -151,29 +151,40 @@ static struct oprofile_operations oprof_axp_ops = {
int __init int __init
oprofile_arch_init(struct oprofile_operations **ops, enum oprofile_cpu *cpu) oprofile_arch_init(struct oprofile_operations **ops, enum oprofile_cpu *cpu)
{ {
struct op_axp_model *lmodel = NULL;
const char *vername = NULL;
switch (implver()) { switch (implver()) {
case IMPLVER_EV4: case IMPLVER_EV4:
model = &op_model_ev4; lmodel = &op_model_ev4;
vername = "EV4";
break; break;
case IMPLVER_EV5: case IMPLVER_EV5:
/* 21164PC has a slightly different set of events. /* 21164PC has a slightly different set of events.
Recognize the chip by the presence of the MAX insns. */ Recognize the chip by the presence of the MAX insns. */
if (!amask(AMASK_MAX)) if (!amask(AMASK_MAX)) {
model = &op_model_pca56; lmodel = &op_model_pca56;
else vername = "PCA56";
model = &op_model_ev5; } else {
lmodel = &op_model_ev5;
vername = "EV5";
}
break; break;
case IMPLVER_EV6: case IMPLVER_EV6:
model = &op_model_ev6; lmodel = &op_model_ev6;
vername = "EV6";
break; break;
default:
model = NULL;
} }
if (!model) if (!lmodel)
return ENODEV; return ENODEV;
model = lmodel;
*ops = &oprof_axp_ops; *ops = &oprof_axp_ops;
*cpu = model->cpu; *cpu = model->cpu;
printk(KERN_INFO "oprofile: using %s performance monitoring.\n",
vername);
return 0; return 0;
} }
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