From: Andrew Cooper <andrew.cooper3@citrix.com>
To: Paul Durrant <paul.durrant@citrix.com>, xen-devel@lists.xenproject.org
Cc: Jan Beulich <jbeulich@suse.com>
Subject: Re: [PATCH] x86/hvm/viridian: save APIC assist vector
Date: Thu, 24 Mar 2016 17:57:33 +0000 [thread overview]
Message-ID: <56F42A8D.3090407@citrix.com> (raw)
In-Reply-To: <1458839997-6597-1-git-send-email-paul.durrant@citrix.com>
On 24/03/16 17:19, Paul Durrant wrote:
> @@ -293,10 +292,11 @@ void viridian_start_apic_assist(struct vcpu *v, int vector)
> * wrong and the VM will most likely hang so force a crash now
> * to make the problem clear.
> */
> - if ( v->arch.hvm_vcpu.viridian.apic_assist.vector >= 0 )
> + if ( v->arch.hvm_vcpu.viridian.apic_assist.vector != 0 )
> domain_crash(v->domain);
>
> - v->arch.hvm_vcpu.viridian.apic_assist.vector = vector;
> + /* Increment the value so that zero is always invalid. */
> + v->arch.hvm_vcpu.viridian.apic_assist.vector = vector + 1;
Can you add a comment to viridan_cpu that a variable named vector
actually holds "vector + 1" ?
It can also be changed to an unsigned value.
> *va |= 1u;
> }
>
> diff --git a/xen/include/public/arch-x86/hvm/save.h b/xen/include/public/arch-x86/hvm/save.h
> index fbd1c6a..fc8e8f9 100644
> --- a/xen/include/public/arch-x86/hvm/save.h
> +++ b/xen/include/public/arch-x86/hvm/save.h
> @@ -588,7 +588,8 @@ struct hvm_viridian_domain_context {
> DECLARE_HVM_SAVE_TYPE(VIRIDIAN_DOMAIN, 15, struct hvm_viridian_domain_context);
>
> struct hvm_viridian_vcpu_context {
> - uint64_t apic_assist;
> + uint64_t apic_assist_msr;
> + uint16_t apic_assist_vector;
An explicit uint16_t[3] _pad; please.
~Andrew
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel
next prev parent reply other threads:[~2016-03-24 17:58 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-24 17:19 [PATCH] x86/hvm/viridian: save APIC assist vector Paul Durrant
2016-03-24 17:57 ` Andrew Cooper [this message]
2016-03-29 8:58 ` Paul Durrant
2016-03-29 8:41 ` Jan Beulich
2016-03-29 8:57 ` Paul Durrant
2016-03-29 9:07 ` Jan Beulich
2016-03-29 9:04 ` Paul Durrant
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=56F42A8D.3090407@citrix.com \
--to=andrew.cooper3@citrix.com \
--cc=jbeulich@suse.com \
--cc=paul.durrant@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 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.