The patch titled
x86: Always probe the NMI watchdog
has been removed from the -mm tree. Its filename was
always-probe-the-nmi-watchdog.patch
This patch was dropped because it was merged into mainline or a subsystem tree
------------------------------------------------------
Subject: x86: Always probe the NMI watchdog
From: Björn Steinbrink <[EMAIL PROTECTED]>
The performance counter allocator relies on the nmi watchdog being probed, so
we have to do that even if the watchdog is not enabled.
Signed-off-by: Björn Steinbrink <[EMAIL PROTECTED]>
Cc: Andi Kleen <[EMAIL PROTECTED]>
Cc: Stephane Eranian <[EMAIL PROTECTED]>
Cc: John Levon <[EMAIL PROTECTED]>
Cc: Philippe Elie <[EMAIL PROTECTED]>
Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
---
arch/i386/kernel/cpu/perfctr-watchdog.c | 11 +++++------
arch/i386/kernel/nmi.c | 3 +++
arch/x86_64/kernel/nmi.c | 3 +++
include/asm-i386/nmi.h | 1 +
include/asm-x86_64/nmi.h | 1 +
5 files changed, 13 insertions(+), 6 deletions(-)
diff -puN arch/i386/kernel/cpu/perfctr-watchdog.c~always-probe-the-nmi-watchdog
arch/i386/kernel/cpu/perfctr-watchdog.c
--- a/arch/i386/kernel/cpu/perfctr-watchdog.c~always-probe-the-nmi-watchdog
+++ a/arch/i386/kernel/cpu/perfctr-watchdog.c
@@ -572,7 +572,7 @@ static struct wd_ops intel_arch_wd_ops =
.evntsel = MSR_ARCH_PERFMON_EVENTSEL0,
};
-static void probe_nmi_watchdog(void)
+void probe_nmi_watchdog(void)
{
switch (boot_cpu_data.x86_vendor) {
case X86_VENDOR_AMD:
@@ -610,17 +610,16 @@ static void probe_nmi_watchdog(void)
int lapic_watchdog_init(unsigned nmi_hz)
{
- if (!wd_ops) {
- probe_nmi_watchdog();
- if (!wd_ops)
- return -1;
+ if (!wd_ops)
+ return -1;
+ /* hack to make sure that we only try to reserver the perfctrs once */
+ if (smp_processor_id() == 0)
if (!wd_ops->reserve()) {
printk(KERN_ERR
"NMI watchdog: cannot reserve perfctrs\n");
return -1;
}
- }
if (!(wd_ops->setup(nmi_hz))) {
printk(KERN_ERR "Cannot setup NMI watchdog on CPU %d\n",
diff -puN arch/i386/kernel/nmi.c~always-probe-the-nmi-watchdog
arch/i386/kernel/nmi.c
--- a/arch/i386/kernel/nmi.c~always-probe-the-nmi-watchdog
+++ a/arch/i386/kernel/nmi.c
@@ -248,6 +248,9 @@ void setup_apic_nmi_watchdog (void *unus
if ((smp_processor_id() != 0) && (atomic_read(&nmi_active) <= 0))
return;
+ /* always probe the watchdog, the perfctr allocator requires that */
+ probe_nmi_watchdog();
+
switch (nmi_watchdog) {
case NMI_LOCAL_APIC:
__get_cpu_var(wd_enabled) = 1; /* enable it before to avoid
race with handler */
diff -puN arch/x86_64/kernel/nmi.c~always-probe-the-nmi-watchdog
arch/x86_64/kernel/nmi.c
--- a/arch/x86_64/kernel/nmi.c~always-probe-the-nmi-watchdog
+++ a/arch/x86_64/kernel/nmi.c
@@ -255,6 +255,9 @@ void setup_apic_nmi_watchdog(void *unuse
if ((smp_processor_id() != 0) && (atomic_read(&nmi_active) <= 0))
return;
+ /* always probe the watchdog, the perfctr allocator requires that */
+ probe_nmi_watchdog();
+
switch (nmi_watchdog) {
case NMI_LOCAL_APIC:
__get_cpu_var(wd_enabled) = 1;
diff -puN include/asm-i386/nmi.h~always-probe-the-nmi-watchdog
include/asm-i386/nmi.h
--- a/include/asm-i386/nmi.h~always-probe-the-nmi-watchdog
+++ a/include/asm-i386/nmi.h
@@ -18,6 +18,7 @@
int do_nmi_callback(struct pt_regs *regs, int cpu);
extern int nmi_watchdog_enabled;
+extern void probe_nmi_watchdog(void);
extern int avail_to_resrv_perfctr_nmi_bit(unsigned int);
extern int avail_to_resrv_perfctr_nmi(unsigned int);
extern int reserve_perfctr_nmi(unsigned int);
diff -puN include/asm-x86_64/nmi.h~always-probe-the-nmi-watchdog
include/asm-x86_64/nmi.h
--- a/include/asm-x86_64/nmi.h~always-probe-the-nmi-watchdog
+++ a/include/asm-x86_64/nmi.h
@@ -45,6 +45,7 @@ extern int panic_on_timeout;
extern int unknown_nmi_panic;
extern int nmi_watchdog_enabled;
+extern void probe_nmi_watchdog(void);
extern int check_nmi_watchdog(void);
extern int avail_to_resrv_perfctr_nmi_bit(unsigned int);
extern int avail_to_resrv_perfctr_nmi(unsigned int);
_
Patches currently in -mm which might be from [EMAIL PROTECTED] are
origin.patch
replace-obscure-constructs-in-fs-block_devc.patch
replace-obscure-constructs-in-fs-block_devc-fix.patch
bd_claim_by_disk-fix-warning.patch
-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html