diff --git a/sys/amd64/amd64/cpu_switch.S b/sys/amd64/amd64/cpu_switch.S index dea3cbe..1254f3f 100644 --- a/sys/amd64/amd64/cpu_switch.S +++ b/sys/amd64/amd64/cpu_switch.S @@ -122,8 +122,7 @@ done_store_dr: 1: movq %rdx,%rcx movl xsave_mask,%eax movl xsave_mask+4,%edx -/* xsave (%r8) */ - .byte 0x41,0x0f,0xae,0x20 + xsave (%r8) movq %rcx,%rdx 2: smsw %ax orb $CR0_TS,%al @@ -499,10 +498,8 @@ ENTRY(resumectx) movq %rax,%rdx shrq $32,%rdx movl $XCR0,%ecx -/* xsetbv */ - .byte 0x0f, 0x01, 0xd1 -/* xrstor (%rbx) */ - .byte 0x0f, 0xae, 0x2b + xsetbv + xrstor (%rbx) jmp 2f 1: fxrstor (%rbx)