Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

x86/asm/entry/64: Fix incorrect symbolic constant usage: R11->ARGOFFSET

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 <dvlasenk@redhat.com>
Signed-off-by: Andy Lutomirski <luto@amacapital.net>
Cc: Alexei Starovoitov <ast@plumgrid.com>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Kees Cook <keescook@chromium.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Will Drewry <wad@chromium.org>
Link: http://lkml.kernel.org/r/1423778052-21038-1-git-send-email-dvlasenk@redhat.com
Link: http://lkml.kernel.org/r/f5e1c4084319a42e5f14d41e2d638949ce66bc08.1424989793.git.luto@amacapital.net
Signed-off-by: Ingo Molnar <mingo@kernel.org>

authored by

Denys Vlasenko and committed by
Ingo Molnar
6e1327bd 49db46a6

+3 -3
+3 -3
arch/x86/kernel/entry_64.S
··· 757 757 * Try to use SYSRET instead of IRET if we're returning to 758 758 * a completely clean 64-bit userspace context. 759 759 */ 760 - movq (RCX-R11)(%rsp), %rcx 761 - cmpq %rcx,(RIP-R11)(%rsp) /* RCX == RIP */ 760 + movq (RCX-ARGOFFSET)(%rsp), %rcx 761 + cmpq %rcx,(RIP-ARGOFFSET)(%rsp) /* RCX == RIP */ 762 762 jne opportunistic_sysret_failed 763 763 764 764 /* ··· 779 779 shr $__VIRTUAL_MASK_SHIFT, %rcx 780 780 jnz opportunistic_sysret_failed 781 781 782 - cmpq $__USER_CS,(CS-R11)(%rsp) /* CS must match SYSRET */ 782 + cmpq $__USER_CS,(CS-ARGOFFSET)(%rsp) /* CS must match SYSRET */ 783 783 jne opportunistic_sysret_failed 784 784 785 785 movq (R11-ARGOFFSET)(%rsp), %r11