OpenCloudOS-Kernel/include/xen/interface
Vitaly Kuznetsov 998c2034c6 xen: Move xen_setup_callback_vector() definition to include/xen/hvm.h
Kbuild test robot reports the following problem on ARM:

  for 'xen_setup_callback_vector' [-Wmissing-prototypes]
1664 | void xen_setup_callback_vector(void) {}
|      ^~~~~~~~~~~~~~~~~~~~~~~~~

The problem is that xen_setup_callback_vector is a x86 only thing, its
definition is present in arch/x86/xen/xen-ops.h but not on ARM. In
events_base.c there is a stub for !CONFIG_XEN_PVHVM but it is not declared
as 'static'.

On x86 the situation is hardly better: drivers/xen/events/events_base.c
doesn't include 'xen-ops.h' from arch/x86/xen/, it includes its namesake
from include/xen/ which also results in a 'no previous prototype' warning.

Currently, xen_setup_callback_vector() has two call sites: one in
drivers/xen/events_base.c and another in arch/x86/xen/suspend_hvm.c. The
former is placed under #ifdef CONFIG_X86 and the later is only compiled
in when CONFIG_XEN_PVHVM.

Resolve the issue by moving xen_setup_callback_vector() declaration to
arch neutral 'include/xen/hvm.h' as the implementation lives in arch
neutral drivers/xen/events/events_base.c.

Reported-by: kbuild test robot <lkp@intel.com>
Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Juergen Gross <jgross@suse.com>
Link: https://lkml.kernel.org/r/20200520161600.361895-1-vkuznets@redhat.com
2020-06-11 15:15:19 +02:00
..
hvm xen: Move xen_setup_callback_vector() definition to include/xen/hvm.h 2020-06-11 15:15:19 +02:00
io xen: Replace zero-length array with flexible-array member 2020-03-05 09:41:58 -06:00
callback.h ia64/xen: Remove Xen support for ia64 2013-12-10 16:11:07 -08:00
elfnote.h xen/pvh: Import PVH-related Xen public interfaces 2017-02-07 08:07:01 -05:00
event_channel.h xen: Use evtchn_type_t as a type for event channels 2020-04-07 12:12:54 +02:00
features.h xen/pvh: Indicate XENFEAT_linux_rsdp_unrestricted to Xen 2018-04-10 09:22:22 -04:00
grant_table.h scripts/spelling.txt: add "an union" pattern and fix typo instances 2017-02-27 18:43:46 -08:00
memory.h x86/xen: Move pv specific parts of arch/x86/xen/mmu.c to mmu_pv.c 2018-09-03 16:50:33 +02:00
nmi.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
physdev.h xen: add support for MSI message groups 2014-03-18 14:40:09 +00:00
platform.h xen: introduce XENPF_settime64 2015-12-21 14:40:57 +00:00
sched.h xen: Sync xen header 2016-09-05 13:52:37 +02:00
vcpu.h x86/xen/time: setup vcpu 0 time info page 2017-11-08 16:33:14 -05:00
version.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
xen-mca.h xen/mcelog: add PPIN to record when available 2019-11-14 10:01:57 +01:00
xen.h xen/privcmd: add IOCTL_PRIVCMD_MMAP_RESOURCE 2018-05-14 15:25:37 +02:00
xenpmu.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00