[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v4 23/33] sgx-epc: Add the reset interface for sgx-epc virt d
From: |
Yang Zhong |
Subject: |
Re: [PATCH v4 23/33] sgx-epc: Add the reset interface for sgx-epc virt device |
Date: |
Wed, 15 Sep 2021 19:33:38 +0800 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
On Tue, Sep 14, 2021 at 08:53:48AM +0200, Philippe Mathieu-Daudé wrote:
> On 7/19/21 1:21 PM, Yang Zhong wrote:
> > If the VM is reset, we need make sure sgx virt epc in clean status.
> > Once the VM is reset, and sgx epc virt device will be reseted by
> > reset callback registered by qemu_register_reset(). Since this epc
> > virt device depend on backend, this reset will call backend reset
> > interface to re-mmap epc to guest.
> >
> > Signed-off-by: Yang Zhong <yang.zhong@intel.com>
> > ---
> > hw/i386/sgx-epc.c | 94 ++++++++++++++++++++++++++++++++++++++++-------
> > 1 file changed, 81 insertions(+), 13 deletions(-)
> >
> > diff --git a/hw/i386/sgx-epc.c b/hw/i386/sgx-epc.c
> > index 924dea22f0..9880d832d5 100644
> > --- a/hw/i386/sgx-epc.c
> > +++ b/hw/i386/sgx-epc.c
> > @@ -18,6 +18,9 @@
> > #include "qapi/visitor.h"
> > #include "target/i386/cpu.h"
> > #include "exec/address-spaces.h"
> > +#include "sysemu/reset.h"
> > +
> > +uint32_t epc_num;
>
> Missing 'static' qualifier.
Philippe, thanks! This Qemu SGX reset solution will be replaced by kernel
patchset made by Paolo(https://www.spinics.net/lists/kvm/msg253930.html).
Yang