From ca76a66975f018c323cb609c0c55a4c8d4acde3b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20Benn=C3=A9e?= Date: Fri, 11 Oct 2019 16:34:05 +0100 Subject: plugin: add qemu_plugin_outs helper MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Having the plugins grab stdout and spew stuff there is a bit ugly and certainly makes the tests look ugly. Provide a hook back into QEMU which can be redirected as needed. Signed-off-by: Alex Bennée Reviewed-by: Aaron Lindsay --- include/qemu/qemu-plugin.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'include/qemu/qemu-plugin.h') diff --git a/include/qemu/qemu-plugin.h b/include/qemu/qemu-plugin.h index ddf267f..a00a7de 100644 --- a/include/qemu/qemu-plugin.h +++ b/include/qemu/qemu-plugin.h @@ -384,4 +384,10 @@ int qemu_plugin_n_vcpus(void); /* returns -1 in user-mode */ int qemu_plugin_n_max_vcpus(void); +/** + * qemu_plugin_outs() - output string via QEMU's logging system + * @string: a string + */ +void qemu_plugin_outs(const char *string); + #endif /* QEMU_PLUGIN_API_H */ -- cgit v1.1