mirror of
https://git.savannah.gnu.org/git/grub.git
synced 2026-10-21 06:49:35 +00:00
Apple fixes.
* grub-core/lib/i386/relocator16.S: Use correct __APPLE__ and not __APPLE_ * grub-core/lib/i386/relocator_common.S [__APPLE__]: Fix gdtdesc definition. * grub-core/lib/i386/relocator64.S [__APPLE__]: Assemble jmp manually.
This commit is contained in:
1 parent
9f3fc8835f
commit
489509f40e
4 files changed
+17
-2
No files matched your search
@@ -84,7 +84,7 @@ VARIABLE(grub_relocator16_start)
|
||||
|
||||
movl %esi, %eax
|
||||
shrl $4, %eax
|
||||
#ifdef __APPLE_
|
||||
#ifdef __APPLE__
|
||||
LOCAL(segment_offset) = LOCAL (segment) - LOCAL (base)
|
||||
LOCAL(idt_offset) = LOCAL(relocator16_idt) - LOCAL (base)
|
||||
LOCAL(cont2_offset) = LOCAL (cont2) - LOCAL(base)
|
||||
|
||||
@@ -109,7 +109,12 @@ VARIABLE(grub_relocator64_rdx)
|
||||
payload and makes this implementation easier. */
|
||||
cld
|
||||
|
||||
#ifdef __APPLE__
|
||||
.byte 0xff, 0x25
|
||||
.quad 0
|
||||
#else
|
||||
jmp *LOCAL(jump_addr) (%rip)
|
||||
#endif
|
||||
|
||||
LOCAL(jump_addr):
|
||||
VARIABLE(grub_relocator64_rip)
|
||||
|
||||
@@ -58,7 +58,7 @@ LOCAL(cont0):
|
||||
LOCAL(jump_vector_offset) = LOCAL(jump_vector) - LOCAL(base)
|
||||
LOCAL(gdt_offset) = LOCAL(gdt) - LOCAL(base)
|
||||
LOCAL(gdt_addr_offset) = LOCAL(gdt_addr) - LOCAL(base)
|
||||
LOCAL(gdtdesc_offset) = LOCAL(gdt_addr) - LOCAL(base)
|
||||
LOCAL(gdtdesc_offset) = LOCAL(gdtdesc) - LOCAL(base)
|
||||
|
||||
lea LOCAL(cont1_offset) (RSI, 1), RAX
|
||||
movl %eax, LOCAL(jump_vector_offset) (RSI, 1)
|
||||
|
||||
Reference in new issue
Block a user