monitor: Do not check TARGET_I386/RISCV to build 'info mem' command
This command is filtered at build-time for i386/x86_64 and riscv32/riscv64 binaries. By using the recently introduced HMPCommand::arch_bitmask flag we can filter it at runtime, making it possible to compile hmp-commands-info.hx once. Since the method depends on a pair of distinct targets, define it in its own stub file. Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Acked-by: Alistair Francis <alistair.francis@wdc.com> Message-Id: <20260427080738.77138-18-philmd@linaro.org>
This commit is contained in:
12
stubs/hmp-cmd-info_mem.c
Normal file
12
stubs/hmp-cmd-info_mem.c
Normal file
@@ -0,0 +1,12 @@
|
||||
/*
|
||||
* Human Monitor 'info mem' stub
|
||||
*
|
||||
* Copyright (c) Linaro
|
||||
*
|
||||
* SPDX-License-Identifier: GPL-2.0-or-later
|
||||
*/
|
||||
|
||||
#include "qemu/osdep.h"
|
||||
#include "monitor/hmp.h"
|
||||
|
||||
HMP_STUB(info_mem)
|
||||
@@ -87,6 +87,7 @@ if have_system
|
||||
stub_ss.add(files('qmp-cpu.c'))
|
||||
stub_ss.add(files('qmp-cpu-s390x.c'))
|
||||
stub_ss.add(files('qmp-cpu-s390x-kvm.c'))
|
||||
stub_ss.add(files('hmp-cmd-info_mem.c'))
|
||||
stub_ss.add(files('hmp-cmd-info_sev.c'))
|
||||
stub_ss.add(files('hmp-cmds-hw-s390x.c'))
|
||||
stub_ss.add(files('hmp-cmds-target-i386.c'))
|
||||
|
||||
Reference in New Issue
Block a user