[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v3 27/33] hmp: Add 'info sgx' command
From: |
Yang Zhong |
Subject: |
[PATCH v3 27/33] hmp: Add 'info sgx' command |
Date: |
Fri, 9 Jul 2021 19:09:49 +0800 |
The command can be used to show the SGX information in the monitor
when SGX is enabled on intel platform.
Signed-off-by: Yang Zhong <yang.zhong@intel.com>
---
hmp-commands-info.hx | 15 +++++++++++++++
include/monitor/hmp.h | 1 +
monitor/hmp-cmds.c | 6 ++++++
3 files changed, 22 insertions(+)
diff --git a/hmp-commands-info.hx b/hmp-commands-info.hx
index fb59c27200..bf207fe941 100644
--- a/hmp-commands-info.hx
+++ b/hmp-commands-info.hx
@@ -880,3 +880,18 @@ SRST
``info dirty_rate``
Display the vcpu dirty rate information.
ERST
+
+#if defined(TARGET_I386)
+ {
+ .name = "sgx",
+ .args_type = "",
+ .params = "",
+ .help = "show intel SGX information",
+ .cmd = hmp_info_sgx,
+ },
+#endif
+
+SRST
+ ``info sgx``
+ Show intel SGX information.
+ERST
diff --git a/include/monitor/hmp.h b/include/monitor/hmp.h
index 3baa1058e2..eba5eda996 100644
--- a/include/monitor/hmp.h
+++ b/include/monitor/hmp.h
@@ -131,5 +131,6 @@ void hmp_replay_delete_break(Monitor *mon, const QDict
*qdict);
void hmp_replay_seek(Monitor *mon, const QDict *qdict);
void hmp_info_dirty_rate(Monitor *mon, const QDict *qdict);
void hmp_calc_dirty_rate(Monitor *mon, const QDict *qdict);
+void hmp_info_sgx(Monitor *mon, const QDict *qdict);
#endif
diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c
index 0942027208..9ebc86190f 100644
--- a/monitor/hmp-cmds.c
+++ b/monitor/hmp-cmds.c
@@ -2230,3 +2230,9 @@ void hmp_info_memory_size_summary(Monitor *mon, const
QDict *qdict)
}
hmp_handle_error(mon, err);
}
+
+void hmp_info_sgx(Monitor *mon, const QDict *qdict)
+{
+ error_setg(errp, QERR_FEATURE_DISABLED, "query-sgx");
+ return NULL;
+}
--
2.29.2.334.gfaefdd61ec
- [PATCH v3 18/33] i386/pc: Add e820 entry for SGX EPC section(s), (continued)
- [PATCH v3 18/33] i386/pc: Add e820 entry for SGX EPC section(s), Yang Zhong, 2021/07/09
- [PATCH v3 19/33] i386: acpi: Add SGX EPC entry to ACPI tables, Yang Zhong, 2021/07/09
- [PATCH v3 21/33] i440fx: Add support for SGX EPC, Yang Zhong, 2021/07/09
- [PATCH v3 20/33] q35: Add support for SGX EPC, Yang Zhong, 2021/07/09
- [PATCH v3 22/33] hostmem-epc: Add the reset interface for EPC backend reset, Yang Zhong, 2021/07/09
- [PATCH v3 23/33] sgx-epc: Add the reset interface for sgx-epc virt device, Yang Zhong, 2021/07/09
- [PATCH v3 24/33] sgx-epc: Avoid bios reset during sgx epc initialization, Yang Zhong, 2021/07/09
- [PATCH v3 25/33] hostmem-epc: Make prealloc consistent with qemu cmdline during reset, Yang Zhong, 2021/07/09
- [PATCH v3 26/33] qmp: Add query-sgx command, Yang Zhong, 2021/07/09
- [PATCH v3 28/33] i386: Add sgx_get_info() interface, Yang Zhong, 2021/07/09
- [PATCH v3 27/33] hmp: Add 'info sgx' command,
Yang Zhong <=
- [PATCH v3 29/33] bitops: Support 32 and 64 bit mask macro, Yang Zhong, 2021/07/09
- [PATCH v3 30/33] qmp: Add the qmp_query_sgx_capabilities(), Yang Zhong, 2021/07/09
- [PATCH v3 31/33] Kconfig: Add CONFIG_SGX support, Yang Zhong, 2021/07/09
- [PATCH v3 32/33] sgx-epc: Add the fill_device_info() callback support, Yang Zhong, 2021/07/09
- [PATCH v3 33/33] doc: Add the SGX doc, Yang Zhong, 2021/07/09
- Re: [PATCH v3 00/33] Qemu SGX virtualization, Jarkko Sakkinen, 2021/07/09