Commit 90ab311a authored by Masahiro Yamada's avatar Masahiro Yamada Committed by Bin Meng
Browse files

x86: simplify ljmp to 32-bit code

You can directly specify the label as the operand for ljmp.

This commit saves 4-byte code.
Signed-off-by: default avatarMasahiro Yamada <>
Reviewed-by: default avatarBin Meng <>
Tested-by: default avatarBin Meng <>
[bmeng: fixed the gas warning]
Signed-off-by: default avatarBin Meng <>
parent 0d915a9a
......@@ -44,10 +44,8 @@ data32 cs lgdt gdt_ptr
/* Finally restore BIST and jump to the 32-bit initialization code */
movw $code32start, %ax
movw %ax, %bp
movl %ecx, %eax
data32 cs ljmp *(%bp)
data32 cs ljmp *code32start
/* 48-bit far pointer */
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment