aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYinghai Lu <yhlu.kernel@gmail.com>2008-09-29 16:39:17 -0400
committerH. Peter Anvin <hpa@zytor.com>2008-09-29 21:34:08 -0400
commit73436a1d2501575f9c2e6ddb26889145e23cefd8 (patch)
treeb612837e4f2035c53d183c9d71ffc0d2c431c00e
parent8f0afaa58e912bbe7d5b0bad9fb024337edf363e (diff)
x86: mtrr_cleanup safe to get more spare regs now
Delay exit to make sure we can actually get the optimal result in as many cases as possible. Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com> Signed-off-by: H. Peter Anvin <hpa@zytor.com>
-rw-r--r--arch/x86/kernel/cpu/mtrr/main.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/arch/x86/kernel/cpu/mtrr/main.c b/arch/x86/kernel/cpu/mtrr/main.c
index bccf57f5b615..ae0ca97e20bd 100644
--- a/arch/x86/kernel/cpu/mtrr/main.c
+++ b/arch/x86/kernel/cpu/mtrr/main.c
@@ -1353,10 +1353,8 @@ static int __init mtrr_cleanup(unsigned address_bits)
1353 nr_mtrr_spare_reg = num_var_ranges - 1; 1353 nr_mtrr_spare_reg = num_var_ranges - 1;
1354 num_reg_good = -1; 1354 num_reg_good = -1;
1355 for (i = num_var_ranges - nr_mtrr_spare_reg; i > 0; i--) { 1355 for (i = num_var_ranges - nr_mtrr_spare_reg; i > 0; i--) {
1356 if (!min_loss_pfn[i]) { 1356 if (!min_loss_pfn[i])
1357 num_reg_good = i; 1357 num_reg_good = i;
1358 break;
1359 }
1360 } 1358 }
1361 1359
1362 index_good = -1; 1360 index_good = -1;