summaryrefslogtreecommitdiff
path: root/arch/x86/lib/zimage.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2013-02-14 17:38:30 +0000
committerSimon Glass <sjg@chromium.org>2013-02-14 20:19:03 -0800
commit96dfc0633aabb4f8fb720d39d9deb29dde08749b (patch)
tree9b58613378b468faa5dd1a7db1db7feba37730fd /arch/x86/lib/zimage.c
parent588a13f742b6d63ac7d5631af11baa01f3a9e80f (diff)
x86: Remove unused real mode code
This code is pretty old and we want to support only 32-bit systems now. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Graeme Russ <graeme.russ@gmail.com>
Diffstat (limited to 'arch/x86/lib/zimage.c')
-rw-r--r--arch/x86/lib/zimage.c23
1 files changed, 0 insertions, 23 deletions
diff --git a/arch/x86/lib/zimage.c b/arch/x86/lib/zimage.c
index 46af391f29..4e9e1f77e5 100644
--- a/arch/x86/lib/zimage.c
+++ b/arch/x86/lib/zimage.c
@@ -33,7 +33,6 @@
#include <asm/io.h>
#include <asm/ptrace.h>
#include <asm/zimage.h>
-#include <asm/realmode.h>
#include <asm/byteorder.h>
#include <asm/bootparam.h>
#ifdef CONFIG_SYS_COREBOOT
@@ -175,16 +174,9 @@ struct boot_params *load_zimage(char *image, unsigned long kernel_size,
else
*load_address = (void *)ZIMAGE_LOAD_ADDR;
-#if (defined CONFIG_ZBOOT_32 || defined CONFIG_X86_NO_REAL_MODE)
printf("Building boot_params at 0x%8.8lx\n", (ulong)setup_base);
memset(setup_base, 0, sizeof(*setup_base));
setup_base->hdr = params->hdr;
-#else
- /* load setup */
- printf("Moving Real-Mode Code to 0x%8.8lx (%d bytes)\n",
- (ulong)setup_base, setup_size);
- memmove(setup_base, image, setup_size);
-#endif
if (bootproto >= 0x0204)
kernel_size = hdr->syssize * 16;
@@ -241,10 +233,8 @@ int setup_zimage(struct boot_params *setup_base, char *cmd_line, int auto_boot,
struct setup_header *hdr = &setup_base->hdr;
int bootproto = get_boot_protocol(hdr);
-#if (defined CONFIG_ZBOOT_32 || defined CONFIG_X86_NO_REAL_MODE)
setup_base->e820_entries = install_e820_map(
ARRAY_SIZE(setup_base->e820_map), setup_base->e820_map);
-#endif
if (bootproto == 0x0100) {
setup_base->screen_info.cl_magic = COMMAND_LINE_MAGIC;
@@ -300,7 +290,6 @@ void boot_zimage(void *setup_base, void *load_address)
#ifdef CONFIG_SYS_COREBOOT
timestamp_add_now(TS_U_BOOT_START_KERNEL);
#endif
-#if defined CONFIG_ZBOOT_32
/*
* Set %ebx, %ebp, and %edi to 0, %esi to point to the boot_params
* structure, and then jump to the kernel. We assume that %cs is
@@ -317,18 +306,6 @@ void boot_zimage(void *setup_base, void *load_address)
"b"(0), "D"(0)
: "%ebp"
);
-#else
- struct pt_regs regs;
-
- memset(&regs, 0, sizeof(struct pt_regs));
- regs.xds = (u32)setup_base >> 4;
- regs.xes = regs.xds;
- regs.xss = regs.xds;
- regs.esp = 0x9000;
- regs.eflags = 0;
- enter_realmode(((u32)setup_base + SETUP_START_OFFSET) >> 4, 0,
- &regs, &regs);
-#endif
}
void setup_pcat_compatibility(void)