diff options
author | Kevin O'Connor <kevin@koconnor.net> | 2013-02-18 21:57:26 -0500 |
---|---|---|
committer | Kevin O'Connor <kevin@koconnor.net> | 2013-02-18 22:00:31 -0500 |
commit | bbd04589279e8ebd4df6a928e06d1cf495fd0d9e (patch) | |
tree | c38c36c1cee4ed37130ef41286e53af5eb51d36c /src/romlayout.S | |
parent | 3e86d6bb2c97626f238e42bb2a2abab2807b8c21 (diff) | |
download | seabios-bbd04589279e8ebd4df6a928e06d1cf495fd0d9e.tar.gz |
Minor assembler enhancements to __csm_return.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'src/romlayout.S')
-rw-r--r-- | src/romlayout.S | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/src/romlayout.S b/src/romlayout.S index 42f87614..b1628eff 100644 --- a/src/romlayout.S +++ b/src/romlayout.S @@ -384,6 +384,7 @@ entry_elf: .code16gcc +// UEFI Compatibility Support Module (CSM) entry point EXPORTFUNC entry_csm entry_csm: // Backup register state @@ -408,22 +409,20 @@ entry_csm: movl $_cfunc32flat_handle_csm, %edx jmp transition32 - .code32 - DECLFUNC __csm_return + .code32 __csm_return: - movl %eax, %ebx - movl $2f, %edx + movl $1f, %edx jmp transition16big .code16gcc // Switch back to original stack -2: movzwl BREGS_code+2(%ebx), %eax - movl %eax, %ecx +1: movzwl BREGS_code+2(%eax), %edx + movl %edx, %ecx shll $4, %ecx - subl %ecx, %ebx - movl %eax, %ss - movl %ebx, %esp + subl %ecx, %eax + movl %edx, %ss + movl %eax, %esp // Restore register state and return. POPBREGS |