This commit is contained in:
phcoder 2009-05-19 15:24:48 +00:00
parent 33db90156a
commit 76f3b6e6b9
3 changed files with 14 additions and 13 deletions

View File

@ -139,6 +139,7 @@ appleldr_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For linux.mod.
linux_mod_SOURCES = loader/i386/efi/linux.c loader/i386/linux_trampoline.S
linux_mod_CFLAGS = $(COMMON_CFLAGS)
linux_mod_ASFLAGS = $(COMMON_ASFLAGS)
linux_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For halt.mod.

View File

@ -31,19 +31,19 @@ VARIABLE(grub_linux_trampoline_start)
base:
pop %rsi
lea (cont1-base)(%rsi, 1), %rax
mov %eax, (jump_vector-base)(%rsi,1)
lea (cont1 - base) (%rsi, 1), %rax
mov %eax, (jump_vector - base) (%rsi, 1)
lea (gdt-base)(%rsi, 1), %rax
mov %rax, (gdtaddr-base)(%rsi,1)
lea (gdt - base) (%rsi, 1), %rax
mov %rax, (gdtaddr - base) (%rsi, 1)
/* Switch to compatibility mode. */
lidt (idtdesc-base)(%rsi,1)
lgdt (gdtdesc-base)(%rsi,1)
lidt (idtdesc - base) (%rsi, 1)
lgdt (gdtdesc - base) (%rsi, 1)
/* Update %cs. Thanks to David Miller for pointing this mistake out. */
ljmp *(jump_vector-base)(%rsi,1)
ljmp *(jump_vector - base) (%rsi, 1)
cont1:
.code32

View File

@ -99,18 +99,18 @@ VARIABLE(grub_xnu_heap_size)
cont0:
lea (cont1-base)(%rsi, 1), %rax
mov %eax, (jump_vector-base)(%rsi,1)
lea (cont1 - base) (%rsi, 1), %rax
mov %eax, (jump_vector - base) (%rsi, 1)
lea (gdt-base)(%rsi, 1), %rax
mov %rax, (gdt_addr-base)(%rsi,1)
lea (gdt - base) (%rsi, 1), %rax
mov %rax, (gdt_addr - base) (%rsi, 1)
/* Switch to compatibility mode. */
lgdt (gdtdesc-base)(%rsi,1)
lgdt (gdtdesc - base) (%rsi, 1)
/* Update %cs. Thanks to David Miller for pointing this mistake out. */
ljmp *(jump_vector-base)(%rsi,1)
ljmp *(jump_vector - base) (%rsi, 1)
cont1:
.code32