ch.so only runs with the patch
test.
v14 addresses a build issue Alex pointed out with the patch test, and removes
a few vestigial lines according to Alex's suggestion. I split this out into
another commit as it's not actually coupled to the patch test.
Rowan Hart (8):
gdbstub: Expos
functions (in particular, the register read and write API)
will call qemu_plugin_get_cb_flags() to check the level is at least the
level they require.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
accel/tcg/plugin-gen.c | 30 ++
include/hw/core/cpu.h
make[1]: *** No rule to make target 'patch-target', needed by
'run-plugin-patch-target-with-libpatch.so'. Stop.
make: *** [/home/alex/lsrc/qemu.git/tests/Makefile.include:56:
run-tcg-tests-x86_64-softmmu] Error 2
You need to ensure vpath is set, something like:
Thanks for the note Alex.
This patch exposes the gdb_write_register function from
gdbstub/gdbstub.c via the exec/gdbstub.h header file to support use in
plugins to write register contents.
Reviewed-by: Alex Bennée
Reviewed-by: Julian Ganz
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
gdbstub/gdbstub.c
specified address space, for example to facilitate
architecture-specific plugins that want to operate on them, for example
reading ARM secure memory.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 93
plugins/api.c
The x86_64-softmmu Makefile seems to have been copy-pasted from the i386
Makefile at some point in the past. Cleaning up a vestigial unused
variable and removing some outdated comments.
Signed-off-by: Rowan Hart
---
tests/tcg/x86_64/Makefile.softmmu-target | 12 +---
1 file changed, 5
ntext of the plugin.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 21 +
plugins/api.c | 18 ++
2 files changed, 39 insertions(+)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu/qemu-plugin.h
This patch updates the plugin version to gate new APIs and adds notes
describing what has been added.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 9 -
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/include/qemu/qemu-plugin.h b
-off-by: Rowan Hart
---
tests/tcg/Makefile.target | 7 +-
tests/tcg/plugins/meson.build | 2 +-
tests/tcg/plugins/patch.c | 241 ++
tests/tcg/x86_64/Makefile.softmmu-target | 7 +
tests/tcg/x86_64/system/patch-target.c| 22
This patch adds a function to the plugins API to allow plugins to write
register contents. It also moves the qemu_plugin_read_register function
so all the register-related functions are grouped together in the file.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu
I've updated this patch to address some notes about the build/test
configuration for the patch plugin. Please check
https://lore.kernel.org/qemu-devel/20250619161547.1401448-1-rowanbh...@gmail.com/T/#t
instead.
On 6/11/25 4:24 PM, Rowan Hart wrote:
This patch series adds several ne
ch.so only runs with the patch
test.
Rowan Hart (1):
plugins: Add enforcement of QEMU_PLUGIN_CB flags in register R/W
callbacks
novafacing (6):
gdbstub: Expose gdb_write_register function to consumers of gdbstub
plugins: Add register write API
plugins: Add memory virtual address write
From: novafacing
This patch updates the plugin version to gate new APIs and adds notes
describing what has been added.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 9 -
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/include
functions (in particular, the register read and write API)
will call qemu_plugin_get_cb_flags() to check the level is at least the
level they require.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
accel/tcg/plugin-gen.c | 30 ++
include/hw/core/cpu.h
to
permit a specified address space, for example to facilitate
architecture-specific plugins that want to operate on them, for example
reading ARM secure memory.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 93
From: novafacing
This patch exposes the gdb_write_register function from
gdbstub/gdbstub.c via the exec/gdbstub.h header file to support use in
plugins to write register contents.
Reviewed-by: Alex Bennée
Reviewed-by: Julian Ganz
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
: Rowan Hart
---
tests/tcg/Makefile.target | 7 +-
tests/tcg/plugins/meson.build | 2 +-
tests/tcg/plugins/patch.c | 241 ++
tests/tcg/x86_64/Makefile.softmmu-target | 7 +
tests/tcg/x86_64/system/patch-target.c| 22 ++
tests
x27;t currently
in the context of the plugin.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 21 +
plugins/api.c | 18 ++
2 files changed, 39 insertions(+)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
From: novafacing
This patch adds a function to the plugins API to allow plugins to write
register contents. It also moves the qemu_plugin_read_register function
so all the register-related functions are grouped together in the file.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
My main concern about the long list of caveats for writing memory is the
user will almost certainly cause weird things to happen which will then
be hard to debug. I can see the patcher example however it would be
useful to know what other practical uses this interface provides.
Of course! My main
I forgot to mention it in the cover letter but v12 also addresses
Pierrick's comments to clean up the patch plug-in. Thanks for the feedback!
functions (in particular, the register read and write API)
will call qemu_plugin_get_cb_flags() to check the level is at least the
level they require.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
accel/tcg/plugin-gen.c | 30 ++
include/hw/core/cpu.h
tested are also
tested by the patcher plugin, making it redundant. We'll circle back on a
hypercalls API in the future as a part of the plugin API, not as a plugin
itself.
Rowan Hart (1):
plugins: Add enforcement of QEMU_PLUGIN_CB flags in register R/W
callbacks
novafacing (6):
gdbstub:
x27;t currently
in the context of the plugin.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 21 +
plugins/api.c | 18 ++
2 files changed, 39 insertions(+)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
From: novafacing
This patch adds a function to the plugins API to allow plugins to write
register contents. It also moves the qemu_plugin_read_register function
so all the register-related functions are grouped together in the file.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
: Rowan Hart
---
tests/tcg/Makefile.target | 1 +
tests/tcg/plugins/meson.build | 2 +-
tests/tcg/plugins/patch.c | 241 ++
tests/tcg/x86_64/Makefile.softmmu-target | 32 ++-
tests/tcg/x86_64/system/patch-target.c| 27 +++
tests
From: novafacing
This patch exposes the gdb_write_register function from
gdbstub/gdbstub.c via the exec/gdbstub.h header file to support use in
plugins to write register contents.
Reviewed-by: Alex Bennée
Reviewed-by: Julian Ganz
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
From: novafacing
This patch updates the plugin version to gate new APIs and adds notes
describing what has been added.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 9 -
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/include
to
permit a specified address space, for example to facilitate
architecture-specific plugins that want to operate on them, for example
reading ARM secure memory.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 93
Signed-off-by: Rowan Hart
---
tests/tcg/Makefile.target | 1 +
tests/tcg/plugins/hypercalls.c | 547 ++
tests/tcg/plugins/meson.build | 2 +-
tests/tcg/x86_64/Makefile.softmmu-target | 6 +-
tests/tcg/x86_64
PM, Rowan Hart wrote:
This patch series adds several new API functions focused on enabling use
cases around reading and writing guest memory from QEMU plugins. To support
these new APIs, some utility functionality around retrieving information about
address spaces is added as well.
The new
I've addressed comments by Alex and Julian WRT the new restrictions on
flags for calling qemu_plugin_read/write_register by relaxing those
restrictions using the same system for setting and getting the current
flag state, and adding a set/clear before each callback invocation.
Please check
htt
ntation for exceptions
(atexit and flush, which do not operate on a specific CPU and in which
current_cpu is not set).
v11 makes the cb flags functions inline and fixes a typo where cpu was asserted
but current_cpu was actually accessed.
Rowan Hart (1):
plugins: Add enforcement of QEMU_P
to
permit a specified address space, for example to facilitate
architecture-specific plugins that want to operate on them, for example
reading ARM secure memory.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 93
From: novafacing
This patch adds a plugin that implements a simple form of hypercalls
from guest code to the plugin by using the register read API. It accepts
only one hypercall, which writes a magic value to guest memory.
Signed-off-by: Rowan Hart
---
tests/tcg/Makefile.target
From: novafacing
This patch updates the plugin version to gate new APIs and adds notes
describing what has been added.
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 9 -
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
functions (in particular, the register read and write API)
will call qemu_plugin_get_cb_flags() to check the level is at least the
level they require.
Signed-off-by: Rowan Hart
---
accel/tcg/plugin-gen.c | 30 ++
include/hw/core/cpu.h | 1 +
include/qemu/plugin.h
: Rowan Hart
---
tests/tcg/Makefile.target | 1 +
tests/tcg/plugins/meson.build | 2 +-
tests/tcg/plugins/patch.c | 297 ++
tests/tcg/x86_64/Makefile.softmmu-target | 32 ++-
tests/tcg/x86_64/system/patch-target.c| 27 ++
tests
x27;t currently
in the context of the plugin.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 21 +
plugins/api.c | 18 ++
2 files changed, 39 insertions(+)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
From: novafacing
This patch adds a function to the plugins API to allow plugins to write
register contents. It also moves the qemu_plugin_read_register function
so all the register-related functions are grouped together in the file.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
From: novafacing
This patch exposes the gdb_write_register function from
gdbstub/gdbstub.c via the exec/gdbstub.h header file to support use in
plugins to write register contents.
Reviewed-by: Alex Bennée
Reviewed-by: Julian Ganz
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
functions (in particular, the register read and write API)
will call qemu_plugin_get_cb_flags() to check the level is at least the
level they require.
Signed-off-by: Rowan Hart
---
accel/tcg/plugin-gen.c | 30 +
include/hw/core/cpu.h | 1 +
include/qemu/plugin.h
From: novafacing
This patch adds a function to the plugins API to allow plugins to write
register contents. It also moves the qemu_plugin_read_register function
so all the register-related functions are grouped together in the file.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
to
permit a specified address space, for example to facilitate
architecture-specific plugins that want to operate on them, for example
reading ARM secure memory.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 93
From: novafacing
This patch adds a plugin that implements a simple form of hypercalls
from guest code to the plugin by using the register read API. It accepts
only one hypercall, which writes a magic value to guest memory.
Signed-off-by: Rowan Hart
---
tests/tcg/Makefile.target
x27;t currently
in the context of the plugin.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 21 +
plugins/api.c | 18 ++
2 files changed, 39 insertions(+)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
: Rowan Hart
---
tests/tcg/Makefile.target | 1 +
tests/tcg/plugins/meson.build | 2 +-
tests/tcg/plugins/patch.c | 297 ++
tests/tcg/x86_64/Makefile.softmmu-target | 32 ++-
tests/tcg/x86_64/system/patch-target.c| 27 ++
tests
ntation for exceptions
(atexit and flush, which do not operate on a specific CPU and in which
current_cpu is not set).
Rowan Hart (1):
plugins: Add enforcement of QEMU_PLUGIN_CB flags in register R/W
callbacks
novafacing (7):
gdbstub: Expose gdb_write_register function to consumers of g
From: novafacing
This patch exposes the gdb_write_register function from
gdbstub/gdbstub.c via the exec/gdbstub.h header file to support use in
plugins to write register contents.
Reviewed-by: Alex Bennée
Reviewed-by: Julian Ganz
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
From: novafacing
This patch updates the plugin version to gate new APIs and adds notes
describing what has been added.
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 9 -
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
>
> However, it should be safe at least for a subset of those callbacks and
I believe there are very valid use-cases for allowing such usage. For
> example, we are currently working on a plugin API exposing traps. In
> those callbacks, users may want to peek at some registers such as
> "ecause" an
to
permit a specified address space, for example to facilitate
architecture-specific plugins that want to operate on them, for example
reading ARM secure memory.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 93
I added another update I missed to v9, so please disregard this version
and check
https://lore.kernel.org/qemu-devel/20250608230819.3382527-1-rowanbh...@gmail.com/T/#t
instead.
-Rowan
From: novafacing
This patch adds a plugin that implements a simple form of hypercalls
from guest code to the plugin by using the register read API. It accepts
only one hypercall, which writes a magic value to guest memory.
Signed-off-by: Rowan Hart
---
tests/tcg/Makefile.target
flags are enforced and qemu_plugin_read_register
can no longer be called from a vcpu_init callback because it does not
request the QEMU_PLUGIN_CB_ flag (nor does it have a mechanism to do
so).
Signed-off-by: Rowan Hart
---
tests/tcg/plugins/insn.c | 22 +-
1 file changed, 1
From: novafacing
This patch updates the plugin version to gate new APIs and adds notes
describing what has been added.
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 9 -
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
: Rowan Hart
---
tests/tcg/Makefile.target | 1 +
tests/tcg/plugins/meson.build | 2 +-
tests/tcg/plugins/patch.c | 297 ++
tests/tcg/x86_64/Makefile.softmmu-target | 32 ++-
tests/tcg/x86_64/system/patch-target.c| 27 ++
tests
functions (in particular, the register read and write API)
will call qemu_plugin_get_cb_flags() to check the level is at least the
level they require.
Signed-off-by: Rowan Hart
---
accel/tcg/plugin-gen.c | 30 ++
include/hw/core/cpu.h | 1 +
include/qemu/plugin.h
ixes qemu_plugin_read_register to return -1 on parameter or flag state
error instead of 0.
Rowan Hart (2):
plugins: Add enforcement of QEMU_PLUGIN_CB flags in register R/W
callbacks
plugins: Remove use of qemu_plugin_read_register where it is not
permitted
novafacing (7):
gdbs
x27;t currently
in the context of the plugin.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 21 +
plugins/api.c | 18 ++
2 files changed, 39 insertions(+)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
From: novafacing
This patch exposes the gdb_write_register function from
gdbstub/gdbstub.c via the exec/gdbstub.h header file to support use in
plugins to write register contents.
Reviewed-by: Alex Bennée
Reviewed-by: Julian Ganz
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
From: novafacing
This patch adds a function to the plugins API to allow plugins to write
register contents. It also moves the qemu_plugin_read_register function
so all the register-related functions are grouped together in the file.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
flags are enforced and qemu_plugin_read_register
can no longer be called from a vcpu_init callback because it does not
request the QEMU_PLUGIN_CB_ flag (nor does it have a mechanism to do
so).
Signed-off-by: Rowan Hart
---
tests/tcg/plugins/insn.c | 22 +-
1 file changed, 1
: Rowan Hart
---
tests/tcg/Makefile.target | 1 +
tests/tcg/plugins/meson.build | 2 +-
tests/tcg/plugins/patch.c | 297 ++
tests/tcg/x86_64/Makefile.softmmu-target | 32 ++-
tests/tcg/x86_64/system/patch-target.c| 27 ++
tests
From: novafacing
This patch updates the plugin version to gate new APIs and adds notes
describing what has been added.
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 9 -
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
From: novafacing
This patch adds a function to the plugins API to allow plugins to write
register contents. It also moves the qemu_plugin_read_register function
so all the register-related functions are grouped together in the file.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
a formatting pass, I left some whitespace that needed removal, some
license text was wrong, and so forth.
v8 reverts a mistake I made extending the size of arrays of TCGHelperInfo
structs, as I misunderstood their sizes. It preserves adding an explicit
zero as the last entry for clarity, however.
functions (in particular, the register read and write API)
will call qemu_plugin_get_cb_flags() to check the level is at least the
level they require.
Signed-off-by: Rowan Hart
---
accel/tcg/plugin-gen.c | 30 ++
include/hw/core/cpu.h | 1 +
include/qemu/plugin.h
From: novafacing
This patch adds a plugin that implements a simple form of hypercalls
from guest code to the plugin by using the register read API. It accepts
only one hypercall, which writes a magic value to guest memory.
Signed-off-by: Rowan Hart
---
tests/tcg/Makefile.target
x27;t currently
in the context of the plugin.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 21 +
plugins/api.c | 18 ++
2 files changed, 39 insertions(+)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
From: novafacing
This patch exposes the gdb_write_register function from
gdbstub/gdbstub.c via the exec/gdbstub.h header file to support use in
plugins to write register contents.
Reviewed-by: Alex Bennée
Reviewed-by: Julian Ganz
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
to
permit a specified address space, for example to facilitate
architecture-specific plugins that want to operate on them, for example
reading ARM secure memory.
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 93
@@ -437,6 +437,10 @@ int qemu_plugin_read_register(struct
qemu_plugin_register *reg, GByteArray *buf)
{
g_assert(current_cpu);
+ if (qemu_plugin_get_cb_flags() == QEMU_PLUGIN_CB_NO_REGS) {
+ return -1;
+ }
+
return gdb_read_register(current_cpu, buf, GPOINTER_TO_INT
to
permit a specified address space, for example to facilitate
architecture-specific plugins that want to operate on them, for example
reading ARM secure memory.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu
a formatting pass, I left some whitespace that needed removal, some
license text was wrong, and so forth.
Rowan Hart (2):
plugins: Add enforcement of QEMU_PLUGIN_CB flags in register R/W
callbacks
plugins: Remove use of qemu_plugin_read_register where it is not
permitted
nov
x27;t currently
in the context of the plugin.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
Reviewed-by: Pierrick Bouvier
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 21 +
plugins/api.c | 18 ++
2 files changed, 39 insertions(+)
From: novafacing
This patch exposes the gdb_write_register function from
gdbstub/gdbstub.c via the exec/gdbstub.h header file to support use in
plugins to write register contents.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
Reviewed-by: Alex Benée
Reviewed-by: Julian Ganz
Reviewed
flags are enforced and qemu_plugin_read_register
can no longer be called from a vcpu_init callback because it does not
request the QEMU_PLUGIN_CB_ flag (nor does it have a mechanism to do
so).
Signed-off-by: Rowan Hart
---
tests/tcg/plugins/insn.c | 22 +-
1 file changed, 1
From: novafacing
This patch adds a plugin that implements a simple form of hypercalls
from guest code to the plugin by using the register read API. It accepts
only one hypercall, which writes a magic value to guest memory.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
---
tests/tcg
From: novafacing
This patch updates the plugin version to gate new APIs and adds notes
describing what has been added.
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 9 -
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
functions (in particular, the register read and write API)
will call qemu_plugin_get_cb_flags() to check the level is at least the
level they require.
Signed-off-by: Rowan Hart
---
accel/tcg/plugin-gen.c | 30 ++
include/hw/core/cpu.h | 1 +
include/qemu/plugin.h
: novafacing
Signed-off-by: Rowan Hart
---
tests/tcg/Makefile.target | 1 +
tests/tcg/plugins/meson.build | 2 +-
tests/tcg/plugins/patch.c | 297 ++
tests/tcg/x86_64/Makefile.softmmu-target | 32 ++-
tests/tcg/x86_64/system/patch
From: novafacing
This patch adds a function to the plugins API to allow plugins to write
register contents. It also moves the qemu_plugin_read_register function
so all the register-related functions are grouped together in the file.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
Reviewed
to
permit a specified address space, for example to facilitate
architecture-specific plugins that want to operate on them, for example
reading ARM secure memory.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 93
plugins
From: novafacing
This patch exposes the gdb_write_register function from
gdbstub/gdbstub.c via the exec/gdbstub.h header file to support use in
plugins to write register contents.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
---
gdbstub/gdbstub.c | 2 +-
include/exec/gdbstub.h
: novafacing
Signed-off-by: Rowan Hart
---
tests/tcg/Makefile.target | 1 +
tests/tcg/plugins/meson.build | 2 +-
tests/tcg/plugins/patch.c | 297 ++
tests/tcg/x86_64/Makefile.softmmu-target | 32 ++-
tests/tcg/x86_64/system/patch
From: novafacing
This patch exposes the gdb_write_register function from
gdbstub/gdbstub.c via the exec/gdbstub.h header file to support use in
plugins to write register contents.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
---
gdbstub/gdbstub.c | 2 +-
include/exec/gdbstub.h
From: novafacing
This patch updates the plugin version to gate new APIs and adds notes
describing what has been added.
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 9 -
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
From: novafacing
This patch adds a plugin that implements a simple form of hypercalls
from guest code to the plugin by using the register read API. It accepts
only one hypercall, which writes a magic value to guest memory.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
---
tests/tcg
From: novafacing
This patch adds a function to the plugins API to allow plugins to write
register contents. It also moves the qemu_plugin_read_register function
so all the register-related functions are grouped together in the file.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
x27;t currently
in the context of the plugin.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 21 +
plugins/api.c | 18 ++
2 files changed, 39 insertions(+)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
functions (in particular, the register read and write API)
will call qemu_plugin_get_cb_flags() to check the level is at least the
level they require.
Signed-off-by: Rowan Hart
---
accel/tcg/plugin-gen.c | 30 ++
include/hw/core/cpu.h | 1 +
include/qemu/plugin.h
a formatting pass, I left some whitespace that needed removal, some
license text was wrong, and so forth.
Rowan Hart (2):
plugins: Add enforcement of QEMU_PLUGIN_CB flags in register R/W
callbacks
plugins: Remove use of qemu_plugin_read_register where it is not
permitted
nov
x27;t currently
in the context of the plugin.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 21 +
plugins/api.c | 18 ++
2 files changed, 39 insertions(+)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
to
permit a specified address space, for example to facilitate
architecture-specific plugins that want to operate on them, for example
reading ARM secure memory.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 93
plugins
From: novafacing
This patch adds a plugin that implements a simple form of hypercalls
from guest code to the plugin by using the register read API. It accepts
only one hypercall, which writes a magic value to guest memory.
Signed-off-by: novafacing
Signed-off-by: Rowan Hart
---
tests/tcg
flags are enforced and qemu_plugin_read_register
can no longer be called from a vcpu_init callback because it does not
request the QEMU_PLUGIN_CB_ flag (nor does it have a mechanism to do
so).
Signed-off-by: Rowan Hart
---
tests/tcg/plugins/insn.c | 22 +-
1 file changed, 1
From: novafacing
This patch updates the plugin version to gate new APIs and adds notes
describing what has been added.
Signed-off-by: Rowan Hart
---
include/qemu/qemu-plugin.h | 9 -
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/include/qemu/qemu-plugin.h b/include/qemu
rsions of these functions in the future if we change our minds!
For v4, I've just updated the enforcement of the QEMU_PLUGIN_CB_ flags to just
use immediate stores, which simplifies the implementation quite a lot and
should be more efficient too. Thanks Pierrick for the suggestion!
: novafacing
Signed-off-by: Rowan Hart
---
tests/tcg/Makefile.target | 1 +
tests/tcg/plugins/meson.build | 2 +-
tests/tcg/plugins/patch.c | 302 ++
tests/tcg/x86_64/Makefile.softmmu-target | 32 ++-
tests/tcg/x86_64/system/patch
1 - 100 of 151 matches
Mail list logo