xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Paul Durrant <Paul.Durrant@citrix.com>
To: Paul Durrant <Paul.Durrant@citrix.com>,
	"xen-devel@lists.xenproject.org" <xen-devel@lists.xenproject.org>
Cc: Ian Jackson <Ian.Jackson@citrix.com>,
	Andrew Cooper <Andrew.Cooper3@citrix.com>
Subject: Re: [PATCH v4 3/3] x86/viridian: implement the crash MSRs
Date: Wed, 22 Mar 2017 12:17:26 +0000	[thread overview]
Message-ID: <1b4af8625736475ca39ebf05c83f9898@AMSPEX02CL03.citrite.net> (raw)
In-Reply-To: <1490184924-20156-4-git-send-email-paul.durrant@citrix.com>

> -----Original Message-----
> From: Paul Durrant [mailto:paul.durrant@citrix.com]
> Sent: 22 March 2017 12:15
> To: xen-devel@lists.xenproject.org
> Cc: Paul Durrant <Paul.Durrant@citrix.com>; Ian Jackson
> <Ian.Jackson@citrix.com>; Andrew Cooper <Andrew.Cooper3@citrix.com>
> Subject: [PATCH v4 3/3] x86/viridian: implement the crash MSRs
> 
> Section 2.4.4 of the Hypervisor Top Level Functional Specification states
> that enabling bit 10 in EDX of CPUID leaf 3 advertises to Windows a set
> of MSRs into which it can write crash information.
> 
> This patch advertises that bit and implements the MSRs such that Xen can
> log the information if a Windows guest crashes.
> 
> Signed-off-by: Paul Durrant <paul.durrant@citrix.com>
> Reviewed-by: Jan Beulich <jbeulich@suse.com>
> Reviewed-by: Wei Liu <wei.liu2@citrix.com>
> ---
> Cc: Ian Jackson <ian.jackson@eu.citrix.com>
> Cc: Paul Durrant <paul.durrant@citrix.com>
> Cc: Andrew Cooper <andrew.cooper3@citrix.com>
> 
> v4:
>  - Name the union in HV_CRASH_CTL_REG_CONTENTS to keep older gcc
> happy
> 
> v3:
>  - Use WARNING level message rather than INFO
> 
> v2:
>  - Make MSRs per-vcpu rather than per-domain
>  - Fix hypervisor stack leak
>  - Replicate BUILD_BOG_ON()
>  - Use gprintk() rather than printk()
> ---
>  docs/man/xl.cfg.pod.5.in           | 10 ++++--
>  tools/libxl/libxl.h                |  6 ++++
>  tools/libxl/libxl_dom.c            |  4 +++
>  tools/libxl/libxl_types.idl        |  1 +
>  xen/arch/x86/hvm/viridian.c        | 69
> ++++++++++++++++++++++++++++++++++++++
>  xen/include/asm-x86/hvm/viridian.h |  1 +
>  xen/include/public/hvm/params.h    |  7 +++-
>  7 files changed, 95 insertions(+), 3 deletions(-)
> 
> diff --git a/docs/man/xl.cfg.pod.5.in b/docs/man/xl.cfg.pod.5.in
> index 52802d5..991960b 100644
> --- a/docs/man/xl.cfg.pod.5.in
> +++ b/docs/man/xl.cfg.pod.5.in
> @@ -1601,11 +1601,17 @@ per-vcpu event channel upcall vectors.
>  Note that this enlightenment will have no effect if the guest is
>  using APICv posted interrupts.
> 
> +=item B<crash_ctl>
> +
> +This group incorporates the crash control MSRs. These enlightenments
> +allow Windows to write crash information such that it can be logged
> +by Xen.
> +
>  =item B<defaults>
> 
>  This is a special value that enables the default set of groups, which
> -is currently the B<base>, B<freq>, B<time_ref_count> and B<apic_assist>
> -groups.
> +is currently the B<base>, B<freq>, B<time_ref_count>, B<apic_assist>
> +and B<crash_ctl> groups.
> 
>  =item B<all>
> 
> diff --git a/tools/libxl/libxl.h b/tools/libxl/libxl.h
> index 72ec39d..af45582 100644
> --- a/tools/libxl/libxl.h
> +++ b/tools/libxl/libxl.h
> @@ -288,6 +288,12 @@
>  #define LIBXL_HAVE_SCHED_CREDIT2_PARAMS 1
> 
>  /*
> + * LIBXL_HAVE_CRASH_CTL indicates that the 'crash_ctl' value
> + * is present in the viridian enlightenment enumeration.
> + */
> +#define LIBXL_HAVE_CRASH_CTL 1

Sorry, I forgot to fix this up. Can this be done at commit assuming the rest of the patch is now ok?

  Paul

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

  reply	other threads:[~2017-03-22 12:17 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-22 12:15 [PATCH v4 0/3] viridian updates Paul Durrant
2017-03-22 12:15 ` [PATCH v4 1/3] x86/viridian: don't put Xen version information in CPUID leaf 2 Paul Durrant
2017-03-22 13:55   ` Jan Beulich
2017-03-22 14:36     ` Paul Durrant
2017-03-22 12:15 ` [PATCH v4 2/3] x86/viridian: make the threshold for HvNotifyLongSpinWait tunable Paul Durrant
2017-03-22 12:15 ` [PATCH v4 3/3] x86/viridian: implement the crash MSRs Paul Durrant
2017-03-22 12:17   ` Paul Durrant [this message]
2017-03-22 12:27     ` Jan Beulich

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=1b4af8625736475ca39ebf05c83f9898@AMSPEX02CL03.citrite.net \
    --to=paul.durrant@citrix.com \
    --cc=Andrew.Cooper3@citrix.com \
    --cc=Ian.Jackson@citrix.com \
    --cc=xen-devel@lists.xenproject.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 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).