x86/asm/entry/64: Fix incorrect symbolic constant usage: R11->ARGOFFSET
authorDenys Vlasenko <[email protected]>
Thu, 26 Feb 2015 22:40:26 +0000 (14:40 -0800)
committerIngo Molnar <[email protected]>
Wed, 4 Mar 2015 21:50:49 +0000 (22:50 +0100)
Since the last fix of this nature, a few more instances have crept
in. Fix them up. No object code changes (constants have the same
value).

Signed-off-by: Denys Vlasenko <[email protected]>
Signed-off-by: Andy Lutomirski <[email protected]>
Cc: Alexei Starovoitov <[email protected]>
Cc: Borislav Petkov <[email protected]>
Cc: Frederic Weisbecker <[email protected]>
Cc: H. Peter Anvin <[email protected]>
Cc: Kees Cook <[email protected]>
Cc: Linus Torvalds <[email protected]>
Cc: Oleg Nesterov <[email protected]>
Cc: Will Drewry <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Link: http://lkml.kernel.org/r/f5e1c4084319a42e5f14d41e2d638949ce66bc08.1424989793.git.luto@amacapital.net
Signed-off-by: Ingo Molnar <[email protected]>
arch/x86/kernel/entry_64.S

index 10074ad9ebf85ed82e552f055baebfa6bb3169f2..a57b3387ec7d59b1213a77c1888e3de327174dea 100644 (file)
@@ -757,8 +757,8 @@ retint_swapgs:              /* return to user-space */
         * Try to use SYSRET instead of IRET if we're returning to
         * a completely clean 64-bit userspace context.
         */
-       movq (RCX-R11)(%rsp), %rcx
-       cmpq %rcx,(RIP-R11)(%rsp)               /* RCX == RIP */
+       movq (RCX-ARGOFFSET)(%rsp), %rcx
+       cmpq %rcx,(RIP-ARGOFFSET)(%rsp)         /* RCX == RIP */
        jne opportunistic_sysret_failed
 
        /*
@@ -779,7 +779,7 @@ retint_swapgs:              /* return to user-space */
        shr $__VIRTUAL_MASK_SHIFT, %rcx
        jnz opportunistic_sysret_failed
 
-       cmpq $__USER_CS,(CS-R11)(%rsp)          /* CS must match SYSRET */
+       cmpq $__USER_CS,(CS-ARGOFFSET)(%rsp)    /* CS must match SYSRET */
        jne opportunistic_sysret_failed
 
        movq (R11-ARGOFFSET)(%rsp), %r11