Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 58d9ce7d authored by Venkatesh Pallipadi's avatar Venkatesh Pallipadi Committed by Linus Torvalds
Browse files

[PATCH] Revert nmi_known_cpu() check during boot option parsing



Commit f2802e7f and its x86 version
(b7471c6d) adds nmi_known_cpu() check
while parsing boot options in x86_64 and i386.

With that, "nmi_watchdog=2" stops working for me on Intel Core 2 CPU
based system.

The problem is, setup_nmi_watchdog is called while parsing the boot
option and identify_cpu is not done yet.  So, the return value of
nmi_known_cpu() is not valid at this point.

So revert that check.  This should not have any adverse effect as the
nmi_known_cpu() check is done again later in enable_lapic_nmi_watchdog().

Signed-off-by: default avatarVenkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Cc: Don Zickus <dzickus@redhat.com>
Cc: Andi Kleen <ak@suse.de>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent bbe1a59b
Loading
Loading
Loading
Loading
+1 −7
Original line number Original line Diff line number Diff line
@@ -310,13 +310,7 @@ static int __init setup_nmi_watchdog(char *str)


	if ((nmi >= NMI_INVALID) || (nmi < NMI_NONE))
	if ((nmi >= NMI_INVALID) || (nmi < NMI_NONE))
		return 0;
		return 0;
	/*

	 * If any other x86 CPU has a local APIC, then
	 * please test the NMI stuff there and send me the
	 * missing bits. Right now Intel P6/P4 and AMD K7 only.
	 */
	if ((nmi == NMI_LOCAL_APIC) && (nmi_known_cpu() == 0))
		return 0;  /* no lapic support */
	nmi_watchdog = nmi;
	nmi_watchdog = nmi;
	return 1;
	return 1;
}
}
+0 −2
Original line number Original line Diff line number Diff line
@@ -302,8 +302,6 @@ int __init setup_nmi_watchdog(char *str)
	if ((nmi >= NMI_INVALID) || (nmi < NMI_NONE))
	if ((nmi >= NMI_INVALID) || (nmi < NMI_NONE))
		return 0;
		return 0;


	if ((nmi == NMI_LOCAL_APIC) && (nmi_known_cpu() == 0))
		return 0;  /* no lapic support */
	nmi_watchdog = nmi;
	nmi_watchdog = nmi;
	return 1;
	return 1;
}
}