For now, we keep the global cpu_get_note_size symbol defined.
Signed-off-by: Pierrick Bouvier <[email protected]>
---
target/i386/arch_dump.c | 8 +++++++-
target/i386/cpu-internal.h | 2 ++
target/i386/cpu.c | 1 +
3 files changed, 10 insertions(+), 1 deletion(-)
diff --git a/target/i386/arch_dump.c b/target/i386/arch_dump.c
index 004a639030e..4d8e9374cd1 100644
--- a/target/i386/arch_dump.c
+++ b/target/i386/arch_dump.c
@@ -430,7 +430,8 @@ int x86_get_dump_info(const CPUState *cs, ArchDumpInfo
*info,
return 0;
}
-ssize_t cpu_get_note_size(int class, int machine, int nr_cpus)
+ssize_t x86_get_note_size(const CPUState *cs, int class, int machine,
+ int nr_cpus)
{
int name_size = 5; /* "CORE" or "QEMU" */
size_t elf_note_size = 0;
@@ -460,3 +461,8 @@ ssize_t cpu_get_note_size(int class, int machine, int
nr_cpus)
return (elf_note_size + qemu_note_size) * nr_cpus;
}
+
+ssize_t cpu_get_note_size(int class, int machine, int nr_cpus)
+{
+ return x86_get_note_size(first_cpu, class, machine, nr_cpus);
+}
diff --git a/target/i386/cpu-internal.h b/target/i386/cpu-internal.h
index 9407b01d415..a01ddaf9254 100644
--- a/target/i386/cpu-internal.h
+++ b/target/i386/cpu-internal.h
@@ -70,6 +70,8 @@ void x86_cpu_machine_reset_cb(void *opaque);
int x86_get_dump_info(const CPUState *cs, ArchDumpInfo *info,
const struct GuestPhysBlockList *guest_phys_blocks);
+ssize_t x86_get_note_size(const CPUState *cs, int class, int machine,
+ int nr_cpus);
#endif /* !CONFIG_USER_ONLY */
#endif /* I386_CPU_INTERNAL_H */
diff --git a/target/i386/cpu.c b/target/i386/cpu.c
index 03efc411ab3..c23c504c5b0 100644
--- a/target/i386/cpu.c
+++ b/target/i386/cpu.c
@@ -10920,6 +10920,7 @@ static const struct SysemuCPUOps i386_sysemu_ops = {
.write_elf32_qemunote = x86_cpu_write_elf32_qemunote,
.write_elf64_qemunote = x86_cpu_write_elf64_qemunote,
.get_dump_info = x86_get_dump_info,
+ .get_note_size = x86_get_note_size,
#ifdef CONFIG_HMP
.monitor_defs = x86_monitor_defs,
#endif
--
2.43.0