x86: Don't use the hypercall table for calling compat hypercalls
authorJuergen Gross <jgross@suse.com>
Mon, 1 Nov 2021 15:20:10 +0000 (16:20 +0100)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Wed, 23 Feb 2022 15:33:42 +0000 (15:33 +0000)
commit69a85336f62d5ec472a4b91d35a9549d5b2b8546
treef131659169dc3641ca28544cfae8567e2311a843
parente7db635f4428cabbb72ba33a6ec6e1465f2169cb
x86: Don't use the hypercall table for calling compat hypercalls

Today the *_op_compat hypercalls call the modern handler functions by
using the entries from the hypercall table. This is resulting in a
not needed indirect function call which can be avoided by using the
correct handler function directly. This is basically a revert of
commit 1252e282311734 ("x86/pv: Export pv_hypercall_table[] rather
than working around it in several ways"), which reasoning no longer
applies, as shim no longer modifies the hypercall table.

The hypercall table can now be made static as there is no external
reference to it any longer.

Commit 834cb8761051f7 ("x86/PV32: fix physdev_op_compat handling")
can be reverted, too, as using the direct call of the correct handler
is already handled fine without that patch.

Signed-off-by: Juergen Gross <jgross@suse.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
xen/arch/x86/compat.c
xen/arch/x86/include/asm/hypercall.h
xen/arch/x86/pv/hypercall.c
xen/arch/x86/x86_64/compat.c