mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 1/1] oprofile: add a warning for unsuppored CPUs
@ 2006-11-29 18:54 Peter Kjellstrom
  0 siblings, 0 replies; only message in thread
From: Peter Kjellstrom @ 2006-11-29 18:54 UTC (permalink / raw)
  To: linux-kernel; +Cc: trivial, levon

From: Peter Kjellstrom <cap@nsc.liu.se>

Oprofile first tries to setup hardware counter based profiling. If this fails
it falls back to timer mode without any clues as to what went wrong. This
patch adds a warning when no supported CPU is found (typically too new CPU
and/or too old kernel).

Signed-off-by: Peter Kjellstrom <cap@nsc.liu.se>

---

--- a/arch/i386/oprofile/init.c
+++ b/arch/i386/oprofile/init.c
@@ -29,6 +29,8 @@ int __init oprofile_arch_init(struct opr

 #ifdef CONFIG_X86_LOCAL_APIC
        ret = op_nmi_init(ops);
+       if (ret == -ENODEV)
+               printk(KERN_INFO "oprofile: hardware counters unavailable, unknown cpu.\n");
 #endif
 #ifdef CONFIG_X86_IO_APIC
        if (ret < 0)

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2006-11-29 18:54 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-11-29 18:54 [PATCH 1/1] oprofile: add a warning for unsuppored CPUs Peter Kjellstrom

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®