#ifndef _ASM_X86_XEN_HYPERCALL_H
#define _ASM_X86_XEN_HYPERCALL_H
#include <linux/kernel.h>
#include <linux/spinlock.h>
#include <linux/errno.h>
#include <linux/string.h>
#include <linux/types.h>
#include <linux/pgtable.h>
#include <trace/events/xen.h>
#include <asm/page.h>
#include <asm/smap.h>
#include <asm/nospec-branch.h>
#include <xen/interface/xen.h>
#include <xen/interface/sched.h>
#include <xen/interface/physdev.h>
#include <xen/interface/platform.h>
#include <xen/interface/xen-mca.h>
struct xen_dm_op_buf;
extern struct { … } hypercall_page[];
#define __HYPERCALL …
#define __HYPERCALL_ENTRY(x) …
#ifdef CONFIG_X86_32
#define __HYPERCALL_RETREG …
#define __HYPERCALL_ARG1REG …
#define __HYPERCALL_ARG2REG …
#define __HYPERCALL_ARG3REG …
#define __HYPERCALL_ARG4REG …
#define __HYPERCALL_ARG5REG …
#else
#define __HYPERCALL_RETREG …
#define __HYPERCALL_ARG1REG …
#define __HYPERCALL_ARG2REG …
#define __HYPERCALL_ARG3REG …
#define __HYPERCALL_ARG4REG …
#define __HYPERCALL_ARG5REG …
#endif
#define __HYPERCALL_DECLS …
#define __HYPERCALL_0PARAM …
#define __HYPERCALL_1PARAM …
#define __HYPERCALL_2PARAM …
#define __HYPERCALL_3PARAM …
#define __HYPERCALL_4PARAM …
#define __HYPERCALL_5PARAM …
#define __HYPERCALL_0ARG() …
#define __HYPERCALL_1ARG(a1) …
#define __HYPERCALL_2ARG(a1,a2) …
#define __HYPERCALL_3ARG(a1,a2,a3) …
#define __HYPERCALL_4ARG(a1,a2,a3,a4) …
#define __HYPERCALL_5ARG(a1,a2,a3,a4,a5) …
#define __HYPERCALL_CLOBBER5 …
#define __HYPERCALL_CLOBBER4 …
#define __HYPERCALL_CLOBBER3 …
#define __HYPERCALL_CLOBBER2 …
#define __HYPERCALL_CLOBBER1 …
#define __HYPERCALL_CLOBBER0 …
#define _hypercall0(type, name) …
#define _hypercall1(type, name, a1) …
#define _hypercall2(type, name, a1, a2) …
#define _hypercall3(type, name, a1, a2, a3) …
#define _hypercall4(type, name, a1, a2, a3, a4) …
static inline long
xen_single_call(unsigned int call,
unsigned long a1, unsigned long a2,
unsigned long a3, unsigned long a4,
unsigned long a5)
{ … }
static __always_inline void __xen_stac(void)
{ … }
static __always_inline void __xen_clac(void)
{ … }
static inline long
privcmd_call(unsigned int call,
unsigned long a1, unsigned long a2,
unsigned long a3, unsigned long a4,
unsigned long a5)
{ … }
#ifdef CONFIG_XEN_PV
static inline int
HYPERVISOR_set_trap_table(struct trap_info *table)
{ … }
static inline int
HYPERVISOR_mmu_update(struct mmu_update *req, int count,
int *success_count, domid_t domid)
{ … }
static inline int
HYPERVISOR_mmuext_op(struct mmuext_op *op, int count,
int *success_count, domid_t domid)
{ … }
static inline int
HYPERVISOR_set_gdt(unsigned long *frame_list, int entries)
{ … }
static inline int
HYPERVISOR_callback_op(int cmd, void *arg)
{ … }
static __always_inline int
HYPERVISOR_set_debugreg(int reg, unsigned long value)
{ … }
static __always_inline unsigned long
HYPERVISOR_get_debugreg(int reg)
{ … }
static inline int
HYPERVISOR_update_descriptor(u64 ma, u64 desc)
{ … }
static inline int
HYPERVISOR_update_va_mapping(unsigned long va, pte_t new_val,
unsigned long flags)
{ … }
static inline int
HYPERVISOR_set_segment_base(int reg, unsigned long value)
{ … }
static inline void
MULTI_fpu_taskswitch(struct multicall_entry *mcl, int set)
{ … }
static inline void
MULTI_update_va_mapping(struct multicall_entry *mcl, unsigned long va,
pte_t new_val, unsigned long flags)
{ … }
static inline void
MULTI_update_descriptor(struct multicall_entry *mcl, u64 maddr,
struct desc_struct desc)
{ … }
static inline void
MULTI_mmu_update(struct multicall_entry *mcl, struct mmu_update *req,
int count, int *success_count, domid_t domid)
{ … }
static inline void
MULTI_mmuext_op(struct multicall_entry *mcl, struct mmuext_op *op, int count,
int *success_count, domid_t domid)
{ … }
static inline void
MULTI_stack_switch(struct multicall_entry *mcl,
unsigned long ss, unsigned long esp)
{ … }
#endif
static __always_inline int
HYPERVISOR_sched_op(int cmd, void *arg)
{ … }
static inline long
HYPERVISOR_set_timer_op(u64 timeout)
{ … }
static inline int
HYPERVISOR_mca(struct xen_mc *mc_op)
{ … }
static inline int
HYPERVISOR_platform_op(struct xen_platform_op *op)
{ … }
static inline long
HYPERVISOR_memory_op(unsigned int cmd, void *arg)
{ … }
static inline int
HYPERVISOR_multicall(void *call_list, uint32_t nr_calls)
{ … }
static inline int
HYPERVISOR_event_channel_op(int cmd, void *arg)
{ … }
static __always_inline int
HYPERVISOR_xen_version(int cmd, void *arg)
{ … }
static inline int
HYPERVISOR_console_io(int cmd, int count, char *str)
{ … }
static inline int
HYPERVISOR_physdev_op(int cmd, void *arg)
{ … }
static inline int
HYPERVISOR_grant_table_op(unsigned int cmd, void *uop, unsigned int count)
{ … }
static inline int
HYPERVISOR_vm_assist(unsigned int cmd, unsigned int type)
{ … }
static inline int
HYPERVISOR_vcpu_op(int cmd, int vcpuid, void *extra_args)
{ … }
static inline int
HYPERVISOR_suspend(unsigned long start_info_mfn)
{ … }
static inline unsigned long __must_check
HYPERVISOR_hvm_op(int op, void *arg)
{ … }
static inline int
HYPERVISOR_xenpmu_op(unsigned int op, void *arg)
{ … }
static inline int
HYPERVISOR_dm_op(
domid_t dom, unsigned int nr_bufs, struct xen_dm_op_buf *bufs)
{ … }
#endif