Skip to content

Commit

Permalink
dump: Add create_win_dump() stub for non-x86 targets
Browse files Browse the repository at this point in the history
Implement the non-x86 create_win_dump(). We can remove
the last TARGET_X86_64 #ifdef'ry in dump.c, which thus
becomes target-independent. Update meson accordingly.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20230225094903.53167-6-philmd@linaro.org>
  • Loading branch information
philmd committed Feb 27, 2023
1 parent efc3146 commit 9724486
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
2 changes: 0 additions & 2 deletions dump/dump.c
Original file line number Diff line number Diff line change
Expand Up @@ -2018,9 +2018,7 @@ static void dump_process(DumpState *s, Error **errp)
DumpQueryResult *result = NULL;

if (s->has_format && s->format == DUMP_GUEST_MEMORY_FORMAT_WIN_DMP) {
#ifdef TARGET_X86_64
create_win_dump(s, errp);
#endif
} else if (s->has_format && s->format != DUMP_GUEST_MEMORY_FORMAT_ELF) {
create_kdump_vmcore(s, errp);
} else {
Expand Down
4 changes: 1 addition & 3 deletions dump/meson.build
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
softmmu_ss.add(files('dump-hmp-cmds.c'))

specific_ss.add(when: 'CONFIG_SOFTMMU', if_true: [files('dump.c'), snappy, lzo])
softmmu_ss.add([files('dump.c', 'dump-hmp-cmds.c'), snappy, lzo])
specific_ss.add(when: 'CONFIG_SOFTMMU', if_true: files('win_dump.c'))
5 changes: 5 additions & 0 deletions dump/win_dump.c
Original file line number Diff line number Diff line change
Expand Up @@ -487,4 +487,9 @@ bool win_dump_available(Error **errp)
return false;
}

void create_win_dump(DumpState *s, Error **errp)
{
win_dump_available(errp);
}

#endif

0 comments on commit 9724486

Please sign in to comment.