qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: Yang Zhong <yang.zhong@intel.com>
Cc: pbonzini@redhat.com, qemu-devel@nongnu.org
Subject: Re: [PATCH] qapi: Cleanup SGX related comments
Date: Wed, 19 Jan 2022 09:41:20 +0000	[thread overview]
Message-ID: <YefcwHgme/jFNVrv@redhat.com> (raw)
In-Reply-To: <20220119092259.GA25040@yangzhon-Virtual>

On Wed, Jan 19, 2022 at 05:22:59PM +0800, Yang Zhong wrote:
> On Wed, Jan 19, 2022 at 09:16:46AM +0000, Daniel P. Berrangé wrote:
> > On Wed, Jan 19, 2022 at 07:00:14AM -0500, Yang Zhong wrote:
> > > The SGX NUMA patches were merged into Qemu 7.0 release, we need
> > > clarify detailed version history information and also change
> > > some related comments, which make SGX related comments clearer.
> > > 
> > > Signed-off-by: Yang Zhong <yang.zhong@intel.com>
> > > ---
> > >  qapi/machine.json     |  4 ++--
> > >  qapi/misc-target.json | 14 +++++++++-----
> > >  2 files changed, 11 insertions(+), 7 deletions(-)
> > 
> > Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
> > 
> > > diff --git a/qapi/machine.json b/qapi/machine.json
> > > index b6a37e17c4..cf47cb63a9 100644
> > > --- a/qapi/machine.json
> > > +++ b/qapi/machine.json
> > > @@ -1207,7 +1207,7 @@
> > >  #
> > >  # @memdev: memory backend linked with device
> > >  #
> > > -# @node: the numa node
> > > +# @node: the numa node (Since: 7.0)
> > >  #
> > >  # Since: 6.2
> > >  ##
> > > @@ -1288,7 +1288,7 @@
> > >  #
> > >  # @memdev: memory backend linked with device
> > >  #
> > > -# @node: the numa node
> > > +# @node: the numa node (Since: 7.0)
> > >  #
> > >  # Since: 6.2
> > >  ##
> > > diff --git a/qapi/misc-target.json b/qapi/misc-target.json
> > > index 1022aa0184..558521bd39 100644
> > > --- a/qapi/misc-target.json
> > > +++ b/qapi/misc-target.json
> > > @@ -344,9 +344,9 @@
> > >  #
> > >  # @node: the numa node
> > >  #
> > > -# @size: the size of epc section
> > > +# @size: the size of EPC section
> > >  #
> > > -# Since: 6.2
> > > +# Since: 7.0
> > >  ##
> > >  { 'struct': 'SGXEPCSection',
> > >    'data': { 'node': 'int',
> > > @@ -365,7 +365,7 @@
> > >  #
> > >  # @flc: true if FLC is supported
> > >  #
> > > -# @sections: The EPC sections info for guest
> > > +# @sections: The EPC sections info for guest(Since: 7.0)
> > 
> > Minor point - a space is needed before '('
> > 
> > >  #
> > >  # Since: 6.2
> > >  ##
> > > @@ -390,7 +390,9 @@
> > >  #
> > >  # -> { "execute": "query-sgx" }
> > >  # <- { "return": { "sgx": true, "sgx1" : true, "sgx2" : true,
> > > -#                  "flc": true, "section-size" : 0 } }
> > > +#                  "flc": true,  "sections":
> > > +#                  [{"node": 0, "size": 67108864},
> > > +#                  {"node": 1, "size": 29360128}]} }
> > >  #
> > >  ##
> > >  { 'command': 'query-sgx', 'returns': 'SGXInfo', 'if': 'TARGET_I386' }
> > > @@ -408,7 +410,9 @@
> > >  #
> > >  # -> { "execute": "query-sgx-capabilities" }
> > >  # <- { "return": { "sgx": true, "sgx1" : true, "sgx2" : true,
> > > -#                  "flc": true, "section-size" : 0 } }
> > > +#                  "flc": true, "section" :
> > > +#                  [{"node": 0, "size": 67108864},
> > > +#                  {"node": 1, "size": 29360128}]} }
> > 
> > The 'section-size' shouldn't be removed here - we still need the
> > command fixed to bring back the 'section-size' as it should not
> > have been deleted.
> > 
> > Adding the 'section' docs is ok though.
> 
> 
>   Thanks Daniel, You mean I need add extra doc like below? 6.2 and 7.0 command
>   description for @query-sgx ?
> 
>   ##
>   # @query-sgx:
>   #
>   # Returns information about SGX
>   #
>   # Returns: @SGXInfo
>   #
>   # Since: 6.2
>   #
>   # Example:
>   #
>   # -> { "execute": "query-sgx" }
>   # <- { "return": { "sgx": true, "sgx1" : true, "sgx2" : true,
>   #                  "flc": true, "section-size" : 0 } }
>   #
>   # Since: 7.0
>   #
>   # Example:
>   #
>   # -> { "execute": "query-sgx" }
>   # <- { "return": { "sgx": true, "sgx1" : true, "sgx2" : true,
>   #                  "flc": true,  "sections":
>   #                  [{"node": 0, "size": 67108864},
>   #                  {"node": 1, "size": 29360128}]} }

No, I'm saying you need to fix the query-sgx command so that it
still reports 'section-size':

   # Example:
   #
   # -> { "execute": "query-sgx" }
   # <- { "return": { "sgx": true, "sgx1" : true, "sgx2" : true,
   #                  "flc": true,  "section-size" : 0,
   #                  "sections": [
   #                     {"node": 0, "size": 67108864},
   #                     {"node": 1, "size": 29360128}] } }


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 :|



      reply	other threads:[~2022-01-19  9:51 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-19 12:00 [PATCH] qapi: Cleanup SGX related comments Yang Zhong
2022-01-19  9:16 ` Daniel P. Berrangé
2022-01-19  9:22   ` Yang Zhong
2022-01-19  9:41     ` Daniel P. Berrangé [this message]

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=YefcwHgme/jFNVrv@redhat.com \
    --to=berrange@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --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).