1700efc1bSEric W. Biederman /* 2700efc1bSEric W. Biederman * linux/arch/i386/kernel/head32.c -- prepare to run common code 3700efc1bSEric W. Biederman * 4700efc1bSEric W. Biederman * Copyright (C) 2000 Andrea Arcangeli <andrea@suse.de> SuSE 5700efc1bSEric W. Biederman * Copyright (C) 2007 Eric Biederman <ebiederm@xmission.com> 6700efc1bSEric W. Biederman */ 7700efc1bSEric W. Biederman 8700efc1bSEric W. Biederman #include <linux/init.h> 9700efc1bSEric W. Biederman #include <linux/start_kernel.h> 10c967da6aSYinghai Lu #include <linux/mm.h> 1172d7c3b3SYinghai Lu #include <linux/memblock.h> 12700efc1bSEric W. Biederman 13a4c81cf6SYinghai Lu #include <asm/setup.h> 14a4c81cf6SYinghai Lu #include <asm/sections.h> 15a4c81cf6SYinghai Lu #include <asm/e820.h> 16816c25e7SThomas Gleixner #include <asm/page.h> 17de934103SThomas Gleixner #include <asm/apic.h> 18de934103SThomas Gleixner #include <asm/io_apic.h> 1947a3d5daSThomas Gleixner #include <asm/bios_ebda.h> 20b40827faSBorislav Petkov #include <asm/tlbflush.h> 215dcd14ecSH. Peter Anvin #include <asm/bootparam_utils.h> 2247a3d5daSThomas Gleixner 2347a3d5daSThomas Gleixner static void __init i386_default_early_setup(void) 2447a3d5daSThomas Gleixner { 25421f91d2SUwe Kleine-König /* Initialize 32bit specific setup functions */ 2647a3d5daSThomas Gleixner x86_init.resources.reserve_resources = i386_reserve_resources; 2747a3d5daSThomas Gleixner x86_init.mpparse.setup_ioapic_ids = setup_ioapic_ids_from_mpc; 2847a3d5daSThomas Gleixner 2947a3d5daSThomas Gleixner reserve_ebda_region(); 3047a3d5daSThomas Gleixner } 31a4c81cf6SYinghai Lu 32a1ed4ddfSAndi Kleen asmlinkage void __init i386_start_kernel(void) 33700efc1bSEric W. Biederman { 345dcd14ecSH. Peter Anvin sanitize_boot_params(&boot_params); 355dcd14ecSH. Peter Anvin 3647a3d5daSThomas Gleixner /* Call the subarch specific early setup function */ 3747a3d5daSThomas Gleixner switch (boot_params.hdr.hardware_subarch) { 38712b6aa8SKuppuswamy Sathyanarayanan case X86_SUBARCH_INTEL_MID: 39712b6aa8SKuppuswamy Sathyanarayanan x86_intel_mid_early_setup(); 403f4110a4SThomas Gleixner break; 41c751e17bSThomas Gleixner case X86_SUBARCH_CE4100: 42c751e17bSThomas Gleixner x86_ce4100_early_setup(); 43c751e17bSThomas Gleixner break; 4447a3d5daSThomas Gleixner default: 4547a3d5daSThomas Gleixner i386_default_early_setup(); 4647a3d5daSThomas Gleixner break; 4747a3d5daSThomas Gleixner } 48a4c81cf6SYinghai Lu 49700efc1bSEric W. Biederman start_kernel(); 50700efc1bSEric W. Biederman } 51