aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPeter Zijlstra <peterz@infradead.org>2009-01-27 15:41:34 -0500
committerH. Peter Anvin <hpa@linux.intel.com>2009-01-27 17:54:44 -0500
commit8f6d86dc4178957d9814b1784848012a927a3898 (patch)
tree66ffa5b780f988f05b82a0dbd73cbec7dd44ea9b
parentcc86c9e0dc1a41451240b948bb39d46bb2536ae8 (diff)
x86: cpu_init(): remove ugly #ifdef construct around debug register clear
Impact: Cleanup While I was looking through the new and improved bootstrap code - great work that, thanks! I found the below a slight improvement. Remove unnecessary ugly #ifdef construct around debug register clear. Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
-rw-r--r--arch/x86/kernel/cpu/common.c25
1 files changed, 11 insertions, 14 deletions
diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c
index f00258462444..3f272d42d09a 100644
--- a/arch/x86/kernel/cpu/common.c
+++ b/arch/x86/kernel/cpu/common.c
@@ -1071,22 +1071,19 @@ void __cpuinit cpu_init(void)
1071 */ 1071 */
1072 if (kgdb_connected && arch_kgdb_ops.correct_hw_break) 1072 if (kgdb_connected && arch_kgdb_ops.correct_hw_break)
1073 arch_kgdb_ops.correct_hw_break(); 1073 arch_kgdb_ops.correct_hw_break();
1074 else { 1074 else
1075#endif 1075#endif
1076 /* 1076 {
1077 * Clear all 6 debug registers: 1077 /*
1078 */ 1078 * Clear all 6 debug registers:
1079 1079 */
1080 set_debugreg(0UL, 0); 1080 set_debugreg(0UL, 0);
1081 set_debugreg(0UL, 1); 1081 set_debugreg(0UL, 1);
1082 set_debugreg(0UL, 2); 1082 set_debugreg(0UL, 2);
1083 set_debugreg(0UL, 3); 1083 set_debugreg(0UL, 3);
1084 set_debugreg(0UL, 6); 1084 set_debugreg(0UL, 6);
1085 set_debugreg(0UL, 7); 1085 set_debugreg(0UL, 7);
1086#ifdef CONFIG_KGDB
1087 /* If the kgdb is connected no debug regs should be altered. */
1088 } 1086 }
1089#endif
1090 1087
1091 fpu_init(); 1088 fpu_init();
1092 1089