Skip to contentSkip to conversation

x86, nops: Missing break resulting in incorrect selection on Intel

tip:x86/urgent tip-bot for Alan Cox 1 participant 1 message Jul 25, 2012 x86

lore
Share & tools
lore
#0 lore raw
Commit-ID:  d6250a3f12edb3a86db9598ffeca3de8b4a219e9
Gitweb:     http://git.kernel.org/tip/d6250a3f12edb3a86db9598ffeca3de8b4a219e9
Author:     Alan Cox <[email protected]>
AuthorDate: Wed, 25 Jul 2012 16:28:19 +0100
Committer:  H. Peter Anvin <[email protected]>
CommitDate: Wed, 25 Jul 2012 08:35:38 -0700

x86, nops: Missing break resulting in incorrect selection on Intel

The Intel case falls through into the generic case which then changes the values. For cases like the P6 it doesn't do the right thing so this seems to be a screwup.

---
 arch/x86/kernel/alternative.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
arch/x86/kernel/alternative.c +1 -1
index 1f84794..73ef56c 100644
@@ -219,7 +219,7 @@ void __init arch_init_ideal_nops(void)
 			ideal_nops = intel_nops;
 #endif
 		}
-
+		break;
 	default:
 #ifdef CONFIG_X86_64
 		ideal_nops = k8_nops;