diff options
author | Sasha Levin <alexander.levin@microsoft.com> | 2018-03-20 16:44:17 -0400 |
---|---|---|
committer | Sasha Levin <alexander.levin@microsoft.com> | 2018-03-20 23:49:54 -0400 |
commit | 509efc5dfd989cf959858c6199f61c269bc76059 (patch) | |
tree | 81974b33e831093eebc1a295acd224e7cded1689 | |
parent | 996f7651f682994ea21bda0da07bf19590fa789d (diff) |
Revert "x86/retpoline/hyperv: Convert assembler indirect jumps"
This reverts commit db8171fb71e4af877f400406d8f114c4021d2ef2.
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
-rw-r--r-- | drivers/hv/hv.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/drivers/hv/hv.c b/drivers/hv/hv.c index 4d0755350387..eab3a88efca5 100644 --- a/drivers/hv/hv.c +++ b/drivers/hv/hv.c @@ -31,7 +31,6 @@ #include <linux/clockchips.h> #include <asm/hyperv.h> #include <asm/mshyperv.h> -#include <asm/nospec-branch.h> #include "hyperv_vmbus.h" /* The one and only */ @@ -101,10 +100,9 @@ static u64 do_hypercall(u64 control, void *input, void *output) void *hypercall_page = hv_context.hypercall_page; __asm__ __volatile__("mov %0, %%r8" : : "r" (output_address) : "r8"); - __asm__ __volatile__(CALL_NOSPEC : - "=a" (hv_status) : + __asm__ __volatile__("call *%3" : "=a" (hv_status) : "c" (control), "d" (input_address), - THUNK_TARGET(hypercall_page)); + "m" (hypercall_page)); return hv_status; @@ -122,12 +120,11 @@ static u64 do_hypercall(u64 control, void *input, void *output) u32 output_address_lo = output_address & 0xFFFFFFFF; void *hypercall_page = hv_context.hypercall_page; - __asm__ __volatile__ (CALL_NOSPEC : "=d"(hv_status_hi), + __asm__ __volatile__ ("call *%8" : "=d"(hv_status_hi), "=a"(hv_status_lo) : "d" (control_hi), "a" (control_lo), "b" (input_address_hi), "c" (input_address_lo), "D"(output_address_hi), - "S"(output_address_lo), - THUNK_TARGET(hypercall_page)); + "S"(output_address_lo), "m" (hypercall_page)); return hv_status_lo | ((u64)hv_status_hi << 32); #endif /* !x86_64 */ |