summaryrefslogtreecommitdiffstats
path: root/src/cpu/x86/smm
diff options
context:
space:
mode:
authorEdward O'Callaghan <funfunctor@folklore1984.net>2017-01-08 19:14:42 +1100
committerPatrick Georgi <pgeorgi@google.com>2017-08-31 15:29:52 +0000
commit4e2294b429b7e4cd259cdd976673353757ac2b29 (patch)
treea4a180cac1c46eda6e1c0b941708cd41d0d5e687 /src/cpu/x86/smm
parent5bf3457bc470b4cc67d1c3ad55c8543305e320f0 (diff)
downloadcoreboot-4e2294b429b7e4cd259cdd976673353757ac2b29.tar.gz
coreboot-4e2294b429b7e4cd259cdd976673353757ac2b29.tar.bz2
coreboot-4e2294b429b7e4cd259cdd976673353757ac2b29.zip
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>
Diffstat (limited to 'src/cpu/x86/smm')
-rw-r--r--src/cpu/x86/smm/smm_stub.S4
-rw-r--r--src/cpu/x86/smm/smmhandler.S4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/cpu/x86/smm/smm_stub.S b/src/cpu/x86/smm/smm_stub.S
index 824a26b85895..32435a04b5d1 100644
--- a/src/cpu/x86/smm/smm_stub.S
+++ b/src/cpu/x86/smm/smm_stub.S
@@ -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:
diff --git a/src/cpu/x86/smm/smmhandler.S b/src/cpu/x86/smm/smmhandler.S
index dd8a0c0cbdc7..b57d015789ad 100644
--- a/src/cpu/x86/smm/smmhandler.S
+++ b/src/cpu/x86/smm/smmhandler.S
@@ -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: