On 10/23/24 10:12, Julian Ganz wrote:
Hi, Pierrick,
October 23, 2024 at 6:39 PM, "Pierrick Bouvier" wrote:
So we could have something like:
/* plugin side */
void on_cf_event(qemu_plugin_cf_event_type, uint64_t from, uint64_t to) {
...
}
We also need the VCPU id, but yes.
Yes!
/* API side */
void qemu_plugin_register_vcpu_syscall_cb(
qemu_plugin_id_t id, qemu_plugin_cf_event_type type,
qemu_plugin_register_vcpu_cf_cb);
We thus would have a new callback type qemu_plugin_vcpu_cf_cb_t added.
For registering several events, we might define enum values for types indexed
on every bit, so we can directly xor the enum to register several types. (same
idea than existing qemu_plugin_mem_rw, but for more values, with a specific ALL
value covering all possibilities).
Does that match what you were thinking?
Yes.
Regards,
Julian