Skip to content
Snippets Groups Projects
Commit 507271d4 authored by Richard Henderson's avatar Richard Henderson Committed by Alex Bennée
Browse files

include/qemu/plugin: Inline qemu_plugin_disable_mem_helpers


Now that we've broken the include loop with cpu.h,
we can bring this inline.

Signed-off-by: default avatarRichard Henderson <richard.henderson@linaro.org>
Reviewed-by: default avatarPhilippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230310195252.210956-8-richard.henderson@linaro.org>
Signed-off-by: default avatarAlex Bennée <alex.bennee@linaro.org>
Message-Id: <20230315174331.2959-18-alex.bennee@linaro.org>
Reviewed-by: default avatarEmilio Cota <cota@braap.org>
parent aa4cf6eb
No related branches found
No related tags found
No related merge requests found
......@@ -14,6 +14,7 @@
#include "qemu/option.h"
#include "qemu/plugin-event.h"
#include "exec/memopidx.h"
#include "hw/core/cpu.h"
/*
* Option parsing/processing.
......@@ -204,7 +205,10 @@ void qemu_plugin_atexit_cb(void);
void qemu_plugin_add_dyn_cb_arr(GArray *arr);
void qemu_plugin_disable_mem_helpers(CPUState *cpu);
static inline void qemu_plugin_disable_mem_helpers(CPUState *cpu)
{
cpu->plugin_mem_cbs = NULL;
}
/**
* qemu_plugin_user_exit(): clean-up callbacks before calling exit callbacks
......
......@@ -553,17 +553,6 @@ void qemu_plugin_user_postfork(bool is_child)
}
}
/*
* Call this function after longjmp'ing to the main loop. It's possible that the
* last instruction of a TB might have used helpers, and therefore the
* "disable" instruction will never execute because it ended up as dead code.
*/
void qemu_plugin_disable_mem_helpers(CPUState *cpu)
{
cpu->plugin_mem_cbs = NULL;
}
static bool plugin_dyn_cb_arr_cmp(const void *ap, const void *bp)
{
return ap == bp;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment