cpu/x86 asm: Just use the correct op suffix

LLVM AS doesn't support as much GNU junk extensions, data16/32
is almost never needed in truth if we just use the correct op
suffix. So do that here, fixes clang/llvm builds with the
integrated-as toggled on.

Change-Id: I6095d03d0289b418a49a10f135de5eb0e117cae0
Also-by: Damien Zammit <damien@zamaudio.com>
Signed-off-by: Damien Zammit <damien@zamaudio.com>
Reviewed-on: https://review.coreboot.org/21218
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
This commit is contained in:
Edward O'Callaghan
2017-01-08 19:14:42 +11:00
committed by Patrick Georgi
parent 5bf3457bc4
commit 4e2294b429
5 changed files with 10 additions and 10 deletions

View File

@@ -31,7 +31,7 @@ _secondary_start:
movw %cs, %ax
movw %ax, %ds
data32 lgdt gdtaddr - _secondary_start
lgdtl gdtaddr - _secondary_start
movl %cr0, %eax
andl $0x7FFAFFD1, %eax /* PG,AM,WP,NE,TS,EM,MP = 0 */

View File

@@ -79,7 +79,7 @@ _start:
movl $(gdtaddr), %ebx
sub $(_start), %ebx
data32 lgdt (%ebx)
lgdtl (%ebx)
movl %cr0, %eax
andl $~CR0_CLEAR_FLAGS, %eax

View File

@@ -68,7 +68,7 @@ fallback_stack_top:
.global _start
_start:
movl $(smm_relocate_gdt), %ebx
data32 lgdt (%ebx)
lgdtl (%ebx)
movl %cr0, %eax
andl $~CR0_CLEAR_FLAGS, %eax
@@ -76,7 +76,7 @@ _start:
movl %eax, %cr0
/* Enable protected mode */
data32 ljmp $0x8, $smm_trampoline32
ljmpl $0x8, $smm_trampoline32
.align 4
smm_relocate_gdt:

View File

@@ -110,7 +110,7 @@ smm_handler_start:
untampered_lapic:
#endif
movw $(smm_gdtptr16 - smm_handler_start + SMM_HANDLER_OFFSET), %bx
data32 lgdt %cs:(%bx)
lgdtl %cs:(%bx)
movl %cr0, %eax
andl $0x7FFAFFD1, %eax /* PG,AM,WP,NE,TS,EM,MP = 0 */
@@ -118,7 +118,7 @@ untampered_lapic:
movl %eax, %cr0
/* Enable protected mode */
data32 ljmp $0x08, $1f
ljmpl $0x08, $1f
.code32
1: