From: "Philippe Mathieu-Daudé" <philmd@redhat.com>
To: Yang Zhong <yang.zhong@intel.com>, qemu-devel@nongnu.org
Cc: pbonzini@redhat.com, eblake@redhat.com,
"Markus Armbruster" <armbru@redhat.com>,
"Marc-André Lureau" <marcandre.lureau@redhat.com>,
seanjc@google.com
Subject: Re: [PATCH v2 1/3] monitor: Add HMP and QMP interfaces
Date: Fri, 10 Sep 2021 14:39:04 +0200 [thread overview]
Message-ID: <fb7d360d-80b5-9bc2-0f6f-f48e04dc08f9@redhat.com> (raw)
In-Reply-To: <20210910102258.46648-2-yang.zhong@intel.com>
On 9/10/21 12:22 PM, Yang Zhong wrote:
> The QMP and HMP interfaces can be used by monitor or QMP tools to retrieve
> the SGX information from VM side when SGX is enabled on Intel platform.
>
> Signed-off-by: Yang Zhong <yang.zhong@intel.com>
> ---
> hmp-commands-info.hx | 15 +++++++++++++
> hw/i386/sgx.c | 29 ++++++++++++++++++++++++
> include/hw/i386/sgx.h | 11 +++++++++
> include/monitor/hmp-target.h | 1 +
> qapi/misc-target.json | 43 ++++++++++++++++++++++++++++++++++++
> target/i386/monitor.c | 36 ++++++++++++++++++++++++++++++
> tests/qtest/qmp-cmd-test.c | 1 +
> 7 files changed, 136 insertions(+)
> create mode 100644 include/hw/i386/sgx.h
> diff --git a/qapi/misc-target.json b/qapi/misc-target.json
> index 3b05ad3dbf..e2a347cc23 100644
> --- a/qapi/misc-target.json
> +++ b/qapi/misc-target.json
> @@ -333,3 +333,46 @@
> { 'command': 'query-sev-attestation-report', 'data': { 'mnonce': 'str' },
> 'returns': 'SevAttestationReport',
> 'if': 'TARGET_I386' }
> +
> +##
> +# @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
> +#
> +# @section-size: The EPC section size for guest
> +#
> +# Since: 6.2
> +##
> +{ 'struct': 'SGXInfo',
> + 'data': { 'sgx': 'bool',
> + 'sgx1': 'bool',
> + 'sgx2': 'bool',
> + 'flc': 'bool',
> + 'section-size': 'uint64'},
> + 'if': 'TARGET_I386' }
Is it possible to restrict it to KVM? Maybe:
'if': { 'all': ['TARGET_I386', 'CONFIG_KVM'] } },
? (I'm not sure).
next prev parent reply other threads:[~2021-09-10 12:48 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-10 10:22 [PATCH v2 0/3] The HMP/QMP interfaces in Qemu SGX Yang Zhong
2021-09-10 10:22 ` [PATCH v2 1/3] monitor: Add HMP and QMP interfaces Yang Zhong
2021-09-10 12:39 ` Philippe Mathieu-Daudé [this message]
2021-09-13 10:37 ` Yang Zhong
2021-09-13 12:42 ` Paolo Bonzini
2021-09-10 13:46 ` Daniel P. Berrangé
2021-09-13 9:35 ` Daniel P. Berrangé
2021-09-13 10:46 ` Yang Zhong
2021-09-13 12:48 ` Paolo Bonzini
2021-09-13 12:56 ` Daniel P. Berrangé
2021-09-13 12:52 ` Yang Zhong
2021-09-13 13:24 ` Daniel P. Berrangé
2021-09-16 6:14 ` Yang Zhong
2021-09-10 10:22 ` [PATCH v2 2/3] qmp: Add the qmp_query_sgx_capabilities() Yang Zhong
2021-09-10 12:41 ` Philippe Mathieu-Daudé
2021-09-13 10:34 ` Yang Zhong
2021-09-10 10:22 ` [PATCH v2 3/3] pc: Cleanup the SGX definitions Yang Zhong
2021-09-10 14:15 ` [PATCH v2 0/3] The HMP/QMP interfaces in Qemu SGX Paolo Bonzini
2021-09-10 14:21 ` Daniel P. Berrangé
2021-09-10 19:10 ` Paolo Bonzini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=fb7d360d-80b5-9bc2-0f6f-f48e04dc08f9@redhat.com \
--to=philmd@redhat.com \
--cc=armbru@redhat.com \
--cc=eblake@redhat.com \
--cc=marcandre.lureau@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=seanjc@google.com \
--cc=yang.zhong@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).