aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/mach-default/setup.c
diff options
context:
space:
mode:
authorYinghai Lu <yhlu.kernel@gmail.com>2008-06-16 22:58:28 -0400
committerIngo Molnar <mingo@elte.hu>2008-07-08 04:38:25 -0400
commit064d25f12014ae1d97c2882f9ab874995321f2b2 (patch)
treea6f39b226bbae5a2abc15d911cdf12d01b9c8c19 /arch/x86/mach-default/setup.c
parentcc9f7a0ccf000d4db5fbdc7b0ae48eefea102f69 (diff)
x86: merge setup_memory_map with e820
... and kill e820_32/64.c and e820_32/64.h Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/mach-default/setup.c')
-rw-r--r--arch/x86/mach-default/setup.c47
1 files changed, 0 insertions, 47 deletions
diff --git a/arch/x86/mach-default/setup.c b/arch/x86/mach-default/setup.c
index 7ae692a76769..2f5e277686b8 100644
--- a/arch/x86/mach-default/setup.c
+++ b/arch/x86/mach-default/setup.c
@@ -142,50 +142,3 @@ static int __init print_ipi_mode(void)
142 142
143late_initcall(print_ipi_mode); 143late_initcall(print_ipi_mode);
144 144
145/**
146 * machine_specific_memory_setup - Hook for machine specific memory setup.
147 *
148 * Description:
149 * This is included late in kernel/setup.c so that it can make
150 * use of all of the static functions.
151 **/
152
153char * __init machine_specific_memory_setup(void)
154{
155 char *who;
156 int new_nr;
157
158
159 who = "BIOS-e820";
160
161 /*
162 * Try to copy the BIOS-supplied E820-map.
163 *
164 * Otherwise fake a memory map; one section from 0k->640k,
165 * the next section from 1mb->appropriate_mem_k
166 */
167 new_nr = boot_params.e820_entries;
168 sanitize_e820_map(boot_params.e820_map,
169 ARRAY_SIZE(boot_params.e820_map),
170 &new_nr);
171 boot_params.e820_entries = new_nr;
172 if (copy_e820_map(boot_params.e820_map, boot_params.e820_entries)
173 < 0) {
174 unsigned long mem_size;
175
176 /* compare results from other methods and take the greater */
177 if (boot_params.alt_mem_k
178 < boot_params.screen_info.ext_mem_k) {
179 mem_size = boot_params.screen_info.ext_mem_k;
180 who = "BIOS-88";
181 } else {
182 mem_size = boot_params.alt_mem_k;
183 who = "BIOS-e801";
184 }
185
186 e820.nr_map = 0;
187 e820_add_region(0, LOWMEMSIZE(), E820_RAM);
188 e820_add_region(HIGH_MEMORY, mem_size << 10, E820_RAM);
189 }
190 return who;
191}