[PATCH v2 0/3] The HMP/QMP interfaces in Qemu SGX

Yang Zhong posted 3 patches 2 years, 7 months ago
Failed in applying to current master (apply log)
hmp-commands-info.hx         | 15 ++++++
hw/i386/sgx.c                | 95 ++++++++++++++++++++++++++++++++++++
include/hw/i386/pc.h         | 11 +++--
include/hw/i386/sgx.h        | 12 +++++
include/monitor/hmp-target.h |  1 +
qapi/misc-target.json        | 61 +++++++++++++++++++++++
target/i386/monitor.c        | 41 ++++++++++++++++
tests/qtest/qmp-cmd-test.c   |  2 +
8 files changed, 233 insertions(+), 5 deletions(-)
create mode 100644 include/hw/i386/sgx.h
[PATCH v2 0/3] The HMP/QMP interfaces in Qemu SGX
Posted by Yang Zhong 2 years, 7 months ago
This patchset supply HMP/QMP interfaces to monitor and Libvirt, with
those interfaces, we can check the SGX info from VM side or check
host SGX capabilities from Libvirt side.

This patchset is splitted from below link(from patch26 to patch30):
https://patchew.org/QEMU/20210719112136.57018-1-yang.zhong@intel.com/

The rest patches are being pulled by Paolo's below link and this new
patchset is based on it.
https://gitlab.com/bonzini/qemu.git tags/for-upstream

Changelog:
=========
v1-->v2:
  - Squashed patch1~patch3 to new patch1(Philippe).
  - Removed the bitops definitions patch, and used the MAKE_64BIT_MASK()
    to handle(Philippe).
  - Removed the 'Fix coredump issue in non-x86 platform' patch and new
    fix in the sgx_get_info()(Paolo).

Qemu SGX-->v1:
patch1~patch5:
  - Moved HMP/QMP from ./monitor to target/i386/monitor.c(Paolo)
  - Added one include/hw/i386/sgx.h to include APIs to avoid "TARGET_XXXX"
    poisoned issue in the ./qapi/qapi-types-misc-target.h.
  - Removed the stubs/sgx-stubs file for non-X86 build issues.
  - Moved the jason definitions from qapi/misc.jason to qapi/misc-target.json, and
    Changed version 6.1 to 6.2.
patch 6:
  - This new patch to fix coredump issue in non-x86 platform.
patch 7:
  - Pure cleanup patch, the issue was caused by cherry-pick tool.


Yang Zhong (3):
  monitor: Add HMP and QMP interfaces
  qmp: Add the qmp_query_sgx_capabilities()
  pc: Cleanup the SGX definitions

 hmp-commands-info.hx         | 15 ++++++
 hw/i386/sgx.c                | 95 ++++++++++++++++++++++++++++++++++++
 include/hw/i386/pc.h         | 11 +++--
 include/hw/i386/sgx.h        | 12 +++++
 include/monitor/hmp-target.h |  1 +
 qapi/misc-target.json        | 61 +++++++++++++++++++++++
 target/i386/monitor.c        | 41 ++++++++++++++++
 tests/qtest/qmp-cmd-test.c   |  2 +
 8 files changed, 233 insertions(+), 5 deletions(-)
 create mode 100644 include/hw/i386/sgx.h


Re: [PATCH v2 0/3] The HMP/QMP interfaces in Qemu SGX
Posted by Paolo Bonzini 2 years, 7 months ago
On 10/09/21 12:22, Yang Zhong wrote:
> This patchset supply HMP/QMP interfaces to monitor and Libvirt, with
> those interfaces, we can check the SGX info from VM side or check
> host SGX capabilities from Libvirt side.
> 
> This patchset is splitted from below link(from patch26 to patch30):
> https://patchew.org/QEMU/20210719112136.57018-1-yang.zhong@intel.com/
> 
> The rest patches are being pulled by Paolo's below link and this new
> patchset is based on it.
> https://gitlab.com/bonzini/qemu.git tags/for-upstream

Queued 1-2, thanks.

For patch 3, I would like to learn more about the whole reset part of 
the series.  Would it be possible to handle it in the kernel without 
having to reopen the vEPC device (there's a possible race where you 
can't reopen and it's a huge mess)?

Paolo


Re: [PATCH v2 0/3] The HMP/QMP interfaces in Qemu SGX
Posted by Daniel P. Berrangé 2 years, 7 months ago
On Fri, Sep 10, 2021 at 04:15:21PM +0200, Paolo Bonzini wrote:
> On 10/09/21 12:22, Yang Zhong wrote:
> > This patchset supply HMP/QMP interfaces to monitor and Libvirt, with
> > those interfaces, we can check the SGX info from VM side or check
> > host SGX capabilities from Libvirt side.
> > 
> > This patchset is splitted from below link(from patch26 to patch30):
> > https://patchew.org/QEMU/20210719112136.57018-1-yang.zhong@intel.com/
> > 
> > The rest patches are being pulled by Paolo's below link and this new
> > patchset is based on it.
> > https://gitlab.com/bonzini/qemu.git tags/for-upstream
> 
> Queued 1-2, thanks.

I had just posted a bunch of comments on patch 1 ...


Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|


Re: [PATCH v2 0/3] The HMP/QMP interfaces in Qemu SGX
Posted by Paolo Bonzini 2 years, 7 months ago
Il ven 10 set 2021, 16:22 Daniel P. Berrangé <berrange@redhat.com> ha
scritto:

> > Queued 1-2, thanks.
>
> I had just posted a bunch of comments on patch 1 ...
>

Sorry, I had already queued it a few hours earlier and just noticed I
hadn't sent out the message.

I have some updates to the main series too, so I might just pick up your
suggestions and send out everything next week or on Sunday.

Paolo


>
> Regards,
> Daniel
> --
> |: https://berrange.com      -o-
> https://www.flickr.com/photos/dberrange :|
> |: https://libvirt.org         -o-
> https://fstop138.berrange.com :|
> |: https://entangle-photo.org    -o-
> https://www.instagram.com/dberrange :|
>
>