This removes the TARGET_ARM condition from the query-gic-capability command. This requires providing a QMP command stub for non-ARM targets. This in turn requires moving the command out of misc-target.json, since that will trigger symbol poisoning errors when built from target independent code. Following the earlier precedent, this creates a misc-arm.json file to hold this ARM specific command. Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Signed-off-by: Daniel P. Berrangé <berrange@redhat.com> Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org> Message-ID: <20250522190542.588267-5-pierrick.bouvier@linaro.org> Reviewed-by: Markus Armbruster <armbru@redhat.com>
193 lines
4.1 KiB
Python
193 lines
4.1 KiB
Python
# -*- Mode: Python -*-
|
|
# vim: filetype=python
|
|
#
|
|
|
|
##
|
|
# @SgxEpcSection:
|
|
#
|
|
# Information about intel SGX EPC section
|
|
#
|
|
# @node: the numa node
|
|
#
|
|
# @size: the size of EPC section
|
|
#
|
|
# Since: 7.0
|
|
##
|
|
{ 'struct': 'SgxEpcSection',
|
|
'data': { 'node': 'int',
|
|
'size': 'uint64'}}
|
|
|
|
##
|
|
# @SgxInfo:
|
|
#
|
|
# Information about intel Safe Guard eXtension (SGX) support
|
|
#
|
|
# @sgx: true if SGX is supported
|
|
#
|
|
# @sgx1: true if SGX1 is supported
|
|
#
|
|
# @sgx2: true if SGX2 is supported
|
|
#
|
|
# @flc: true if FLC is supported
|
|
#
|
|
# @sections: The EPC sections information (Since: 7.0)
|
|
#
|
|
# Since: 6.2
|
|
##
|
|
{ 'struct': 'SgxInfo',
|
|
'data': { 'sgx': 'bool',
|
|
'sgx1': 'bool',
|
|
'sgx2': 'bool',
|
|
'flc': 'bool',
|
|
'sections': ['SgxEpcSection']},
|
|
'if': 'TARGET_I386' }
|
|
|
|
##
|
|
# @query-sgx:
|
|
#
|
|
# Returns information about configured SGX capabilities of guest
|
|
#
|
|
# Returns: @SgxInfo
|
|
#
|
|
# Since: 6.2
|
|
#
|
|
# .. qmp-example::
|
|
#
|
|
# -> { "execute": "query-sgx" }
|
|
# <- { "return": { "sgx": true, "sgx1" : true, "sgx2" : true,
|
|
# "flc": true,
|
|
# "sections": [{"node": 0, "size": 67108864},
|
|
# {"node": 1, "size": 29360128}]} }
|
|
##
|
|
{ 'command': 'query-sgx', 'returns': 'SgxInfo', 'if': 'TARGET_I386' }
|
|
|
|
##
|
|
# @query-sgx-capabilities:
|
|
#
|
|
# Returns information about SGX capabilities of host
|
|
#
|
|
# Returns: @SgxInfo
|
|
#
|
|
# Since: 6.2
|
|
#
|
|
# .. qmp-example::
|
|
#
|
|
# -> { "execute": "query-sgx-capabilities" }
|
|
# <- { "return": { "sgx": true, "sgx1" : true, "sgx2" : true,
|
|
# "flc": true,
|
|
# "section" : [{"node": 0, "size": 67108864},
|
|
# {"node": 1, "size": 29360128}]} }
|
|
##
|
|
{ 'command': 'query-sgx-capabilities', 'returns': 'SgxInfo', 'if': 'TARGET_I386' }
|
|
|
|
|
|
##
|
|
# @EvtchnPortType:
|
|
#
|
|
# An enumeration of Xen event channel port types.
|
|
#
|
|
# @closed: The port is unused.
|
|
#
|
|
# @unbound: The port is allocated and ready to be bound.
|
|
#
|
|
# @interdomain: The port is connected as an interdomain interrupt.
|
|
#
|
|
# @pirq: The port is bound to a physical IRQ (PIRQ).
|
|
#
|
|
# @virq: The port is bound to a virtual IRQ (VIRQ).
|
|
#
|
|
# @ipi: The post is an inter-processor interrupt (IPI).
|
|
#
|
|
# Since: 8.0
|
|
##
|
|
{ 'enum': 'EvtchnPortType',
|
|
'data': ['closed', 'unbound', 'interdomain', 'pirq', 'virq', 'ipi'],
|
|
'if': 'TARGET_I386' }
|
|
|
|
##
|
|
# @EvtchnInfo:
|
|
#
|
|
# Information about a Xen event channel port
|
|
#
|
|
# @port: the port number
|
|
#
|
|
# @vcpu: target vCPU for this port
|
|
#
|
|
# @type: the port type
|
|
#
|
|
# @remote-domain: remote domain for interdomain ports
|
|
#
|
|
# @target: remote port ID, or virq/pirq number
|
|
#
|
|
# @pending: port is currently active pending delivery
|
|
#
|
|
# @masked: port is masked
|
|
#
|
|
# Since: 8.0
|
|
##
|
|
{ 'struct': 'EvtchnInfo',
|
|
'data': {'port': 'uint16',
|
|
'vcpu': 'uint32',
|
|
'type': 'EvtchnPortType',
|
|
'remote-domain': 'str',
|
|
'target': 'uint16',
|
|
'pending': 'bool',
|
|
'masked': 'bool'},
|
|
'if': 'TARGET_I386' }
|
|
|
|
|
|
##
|
|
# @xen-event-list:
|
|
#
|
|
# Query the Xen event channels opened by the guest.
|
|
#
|
|
# Returns: list of open event channel ports.
|
|
#
|
|
# Since: 8.0
|
|
#
|
|
# .. qmp-example::
|
|
#
|
|
# -> { "execute": "xen-event-list" }
|
|
# <- { "return": [
|
|
# {
|
|
# "pending": false,
|
|
# "port": 1,
|
|
# "vcpu": 1,
|
|
# "remote-domain": "qemu",
|
|
# "masked": false,
|
|
# "type": "interdomain",
|
|
# "target": 1
|
|
# },
|
|
# {
|
|
# "pending": false,
|
|
# "port": 2,
|
|
# "vcpu": 0,
|
|
# "remote-domain": "",
|
|
# "masked": false,
|
|
# "type": "virq",
|
|
# "target": 0
|
|
# }
|
|
# ]
|
|
# }
|
|
##
|
|
{ 'command': 'xen-event-list',
|
|
'returns': ['EvtchnInfo'],
|
|
'if': 'TARGET_I386' }
|
|
|
|
##
|
|
# @xen-event-inject:
|
|
#
|
|
# Inject a Xen event channel port (interrupt) to the guest.
|
|
#
|
|
# @port: The port number
|
|
#
|
|
# Since: 8.0
|
|
#
|
|
# .. qmp-example::
|
|
#
|
|
# -> { "execute": "xen-event-inject", "arguments": { "port": 1 } }
|
|
# <- { "return": { } }
|
|
##
|
|
{ 'command': 'xen-event-inject',
|
|
'data': { 'port': 'uint32' },
|
|
'if': 'TARGET_I386' }
|