All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Xu, Quan" <quan.xu@intel.com>
To: Andrew Cooper <andrew.cooper3@citrix.com>,
	"xen-devel@lists.xen.org" <xen-devel@lists.xen.org>
Cc: "ian.jackson@eu.citrix.com" <ian.jackson@eu.citrix.com>,
	"tim@xen.org" <tim@xen.org>, "keir@xen.org" <keir@xen.org>,
	"ian.campbell@citrix.com" <ian.campbell@citrix.com>,
	"jbeulich@suse.com" <jbeulich@suse.com>
Subject: Re: [PATCH 2/6] vTPM: add HVM_PARAM_STUBDOM_VTPM parameter for HVM virtual machine
Date: Thu, 30 Oct 2014 12:05:26 +0000	[thread overview]
Message-ID: <945CA011AD5F084CBEA3E851C0AB28890E81CCD8@SHSMSX101.ccr.corp.intel.com> (raw)
In-Reply-To: <545225D2.8090203@citrix.com>



> -----Original Message-----
> From: Andrew Cooper [mailto:andrew.cooper3@citrix.com]
> Sent: Thursday, October 30, 2014 7:50 PM
> To: Xu, Quan; xen-devel@lists.xen.org
> Cc: keir@xen.org; ian.campbell@citrix.com; tim@xen.org;
> ian.jackson@eu.citrix.com; jbeulich@suse.com
> Subject: Re: [Xen-devel] [PATCH 2/6] vTPM: add
> HVM_PARAM_STUBDOM_VTPM parameter for HVM virtual machine
> 
> On 30/10/14 07:38, Quan Xu wrote:
> > Signed-off-by: Quan Xu <quan.xu@intel.com>
> 
> What is the purpose of this parameter?  A patch like this is currently
> unacceptable, especially as the libxl hunk indicates that the parameter name
> does not match whatever information you are putting into it.
> 
Thanks for your suggestion. 
This parameter tell the Qemu whether to register Qemu vTPM frontend in xen_hvm_init().
Qemu will get the parameter value by xc_get_hvm_param(). How can I change it?


> > ---
> >  tools/libxl/libxl_dom.c         | 2 ++
> >  xen/arch/x86/hvm/hvm.c          | 3 +++
> >  xen/include/public/hvm/params.h | 1 +
> >  3 files changed, 6 insertions(+)
> >
> > diff --git a/tools/libxl/libxl_dom.c b/tools/libxl/libxl_dom.c index
> > 74ea84b..a60e8c9 100644
> > --- a/tools/libxl/libxl_dom.c
> > +++ b/tools/libxl/libxl_dom.c
> > @@ -291,6 +291,8 @@ static void hvm_set_conf_params(xc_interface
> > *handle, uint32_t domid,  #if defined(__i386__) || defined(__x86_64__)
> >      xc_hvm_param_set(handle, domid, HVM_PARAM_HPET_ENABLED,
> >                      libxl_defbool_val(info->u.hvm.hpet));
> > +    xc_set_hvm_param(handle, domid, HVM_PARAM_STUBDOM_VTPM,
> > +                     info->num_vtpms);
> >  #endif
> >      xc_hvm_param_set(handle, domid, HVM_PARAM_TIMER_MODE,
> timer_mode(info));
> >      xc_hvm_param_set(handle, domid, HVM_PARAM_VPT_ALIGN, diff --git
> > a/xen/arch/x86/hvm/hvm.c b/xen/arch/x86/hvm/hvm.c index
> > 78f519d..39e4c11 100644
> > --- a/xen/arch/x86/hvm/hvm.c
> > +++ b/xen/arch/x86/hvm/hvm.c
> > @@ -5696,6 +5696,9 @@ long do_hvm_op(unsigned long op,
> > XEN_GUEST_HANDLE_PARAM(void) arg)
> >
> >                  break;
> >              }
> > +            case HVM_PARAM_STUBDOM_VTPM:
> > +                rc = 0;
> > +                break;
> >              }
> >
> >              if ( rc == 0 )
> > diff --git a/xen/include/public/hvm/params.h
> > b/xen/include/public/hvm/params.h index 3c51072..333c131 100644
> > --- a/xen/include/public/hvm/params.h
> > +++ b/xen/include/public/hvm/params.h
> > @@ -56,6 +56,7 @@
> >
> >  #if defined(__i386__) || defined(__x86_64__)
> >
> > +#define HVM_PARAM_STUBDOM_VTPM 8
> 
> New params should be added to the end of the number range.  8 is not up for
> grabs.
> 
> ~Andrew
> 
> >  /*
> >   * Viridian enlightenments
> >   *

  reply	other threads:[~2014-10-30 12:05 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-30  7:38 [PATCH 0/6] vTPM: Xen stubdom vTPM for HVM virtual machine Quan Xu
2014-10-30  7:38 ` [PATCH 1/6] vTPM: event channel bind interdomain with para/hvm " Quan Xu
     [not found]   ` <945CA011AD5F084CBEA3E851C0AB28890E81D119@SHSMSX101.ccr.corp.intel.com>
     [not found]     ` <54528379.5080107@tycho.nsa.gov>
2014-10-31  2:06       ` FW: FW: " Xu, Quan
2014-11-06 16:55       ` Xu, Quan
2014-11-07  7:15         ` Xu, Quan
2014-10-30  7:38 ` [PATCH 2/6] vTPM: add HVM_PARAM_STUBDOM_VTPM parameter for HVM " Quan Xu
2014-10-30 11:49   ` Andrew Cooper
2014-10-30 12:05     ` Xu, Quan [this message]
2014-10-30 12:17       ` Andrew Cooper
2014-10-30 13:34         ` Stefano Stabellini
2014-10-30 14:22           ` Xu, Quan
2014-10-31 17:50             ` Stefano Stabellini
2014-11-02 11:03               ` Xu, Quan
2014-10-30 14:13         ` Xu, Quan
2014-10-31  7:01     ` Xu, Quan
2014-10-30  7:38 ` [PATCH 3/6] vTPM: limit libxl__add_vtpms() function to para " Quan Xu
2014-10-30  7:38 ` [PATCH 4/6] vTPM: add TPM TCPA and SSDT for HVM virtual machine when vTPM is added Quan Xu
2014-10-30  7:38 ` [PATCH 5/6] vTPM: add vTPM device for HVM virtual machine Quan Xu
2014-10-30  7:38 ` [PATCH 6/6] vTPM: add QEMU_STUBDOM_VTPM compile option Quan Xu
2014-11-03 11:30 ` [PATCH 0/6] vTPM: Xen stubdom vTPM for HVM virtual machine Stefano Stabellini
2014-11-05  9:18   ` Xu, Quan
2014-11-05 11:01     ` Stefano Stabellini
2014-11-05 13:20       ` Xu, Quan

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=945CA011AD5F084CBEA3E851C0AB28890E81CCD8@SHSMSX101.ccr.corp.intel.com \
    --to=quan.xu@intel.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=ian.campbell@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=jbeulich@suse.com \
    --cc=keir@xen.org \
    --cc=tim@xen.org \
    --cc=xen-devel@lists.xen.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.