mirror of
https://github.com/torvalds/linux.git
synced 2026-04-18 06:44:00 -04:00
Allow the creation of hypervisor and trace remote events with a single macro HYP_EVENT(). That macro expands in the kernel side to add all the required declarations (based on REMOTE_EVENT()) as well as in the hypervisor side to create the trace_<event>() function. Signed-off-by: Vincent Donnefort <vdonnefort@google.com> Link: https://patch.msgid.link/20260309162516.2623589-28-vdonnefort@google.com Signed-off-by: Marc Zyngier <maz@kernel.org>
17 lines
490 B
C
17 lines
490 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
|
|
#define REMOTE_EVENT_INCLUDE_FILE arch/arm64/include/asm/kvm_hypevents.h
|
|
|
|
#define REMOTE_EVENT_SECTION "_hyp_events"
|
|
|
|
#define HE_STRUCT(__args) __args
|
|
#define HE_PRINTK(__args...) __args
|
|
#define he_field re_field
|
|
|
|
#define HYP_EVENT(__name, __proto, __struct, __assign, __printk) \
|
|
REMOTE_EVENT(__name, 0, RE_STRUCT(__struct), RE_PRINTK(__printk))
|
|
|
|
#define HYP_EVENT_MULTI_READ
|
|
#include <trace/define_remote_events.h>
|
|
#undef HYP_EVENT_MULTI_READ
|