Make the 'readline' value of MonitorMode and the
'human-monitor-command' command conditional on CONFIG_HMP, so
they are only available when HMP support is compiled in.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
qapi/control.json | 4 +++-
qapi/misc.json | 3 ++-
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/qapi/control.json b/qapi/control.json
index 9a5302193d6..9898552814b 100644
--- a/qapi/control.json
+++ b/qapi/control.json
@@ -186,7 +186,9 @@
#
# Since: 5.0
##
-{ 'enum': 'MonitorMode', 'data': [ 'readline', 'control' ] }
+{ 'enum': 'MonitorMode', 'data': [
+ { 'name': 'readline', 'if': 'CONFIG_HMP' },
+ 'control' ] }
##
# @MonitorOptions:
diff --git a/qapi/misc.json b/qapi/misc.json
index 22b7afed9f6..a21ba61b96e 100644
--- a/qapi/misc.json
+++ b/qapi/misc.json
@@ -247,7 +247,8 @@
{ 'command': 'human-monitor-command',
'data': {'command-line': 'str', '*cpu-index': 'int'},
'returns': 'str',
- 'features': [ 'savevm-monitor-nodes' ] }
+ 'features': [ 'savevm-monitor-nodes' ],
+ 'if': 'CONFIG_HMP' }
##
# @getfd:
--
2.54.0