This allows a specific cpu to report the size of the ELF notes it needs to dump its state, alongside get_dump_info.
Reviewed-by: Anton Johansson <[email protected]> Signed-off-by: Pierrick Bouvier <[email protected]> --- include/hw/core/sysemu-cpu-ops.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/include/hw/core/sysemu-cpu-ops.h b/include/hw/core/sysemu-cpu-ops.h index 2c7d0b94767..1ad482f9685 100644 --- a/include/hw/core/sysemu-cpu-ops.h +++ b/include/hw/core/sysemu-cpu-ops.h @@ -100,6 +100,13 @@ typedef struct SysemuCPUOps { */ int (*get_dump_info)(const CPUState *cpu, ArchDumpInfo *info, const GuestPhysBlockList *guest_phys_blocks); + /** + * @get_note_size: returns the size of the ELF notes needed to dump + * @nr_cpus cpus, for the ELF @class and @machine reported by + * @get_dump_info. Must be set if @get_dump_info is set. + */ + ssize_t (*get_note_size)(const CPUState *cpu, int class, int machine, + int nr_cpus); /** * @internal_is_big_endian: Callback to return %true if a CPU which supports * runtime configurable endianness is currently big-endian. -- 2.47.3
