When configuring QEMU with --without-default-devices and
not including machines using a GIC, the GIC model is not
built in but the 'query-gic-capabilities' command still
returns false hopes about GIC:
{"execute": "query-gic-capabilities"}
{"return": [{"emulated": true, "version": 3, "kernel": false}, {"emulated": true,
"version": 2, "kernel": false}]}
Restrict the command to when the GIC is available. If it
isn't we'll get:
{ "execute": "query-gic-capabilities" }
{"error": {"class": "CommandNotFound", "desc": "The command
query-gic-capabilities has not been found"}}
Resolves:https://gitlab.com/qemu-project/qemu/-/issues/2484
Signed-off-by: Philippe Mathieu-Daudé<philmd@linaro.org>
---
qapi/misc-target.json | 4 ++--
hw/intc/arm_gic_qmp.c | 2 ++
hw/intc/meson.build | 2 +-
3 files changed, 5 insertions(+), 3 deletions(-)