All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] xen: update_runstate_area for 32 bit PV on HVM guests
@ 2010-05-28 14:45 Stefano Stabellini
  2010-05-28 14:54 ` Jan Beulich
  0 siblings, 1 reply; 4+ messages in thread
From: Stefano Stabellini @ 2010-05-28 14:45 UTC (permalink / raw)
  To: xen-devel

Hi all,
the current implementation of update_runstate_area is unable to handle
32 bit PV on HVM guests because the check is_pv_32on64_domain doesn't
cover that case. This patch fixes it.

Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>

---

diff -r 26c2922da53c xen/arch/x86/domain.c
--- a/xen/arch/x86/domain.c	Thu May 27 09:39:47 2010 +0100
+++ b/xen/arch/x86/domain.c	Fri May 28 15:42:28 2010 +0100
@@ -1315,7 +1315,9 @@
         return;
 
 #ifdef CONFIG_COMPAT
-    if ( is_pv_32on64_domain(v->domain) )
+    if ( is_pv_32on64_domain(v->domain) ||
+         (is_hvm_pv_evtchn_domain(v->domain) &&
+          has_32bit_shinfo(v->domain)) )
     {
         struct compat_vcpu_runstate_info info;

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] xen: update_runstate_area for 32 bit PV on HVM guests
  2010-05-28 14:45 [PATCH] xen: update_runstate_area for 32 bit PV on HVM guests Stefano Stabellini
@ 2010-05-28 14:54 ` Jan Beulich
  2010-05-28 15:01   ` Stefano Stabellini
  0 siblings, 1 reply; 4+ messages in thread
From: Jan Beulich @ 2010-05-28 14:54 UTC (permalink / raw)
  To: Stefano Stabellini, xen-devel

>>> On 28.05.10 at 16:45, Stefano Stabellini <stefano.stabellini@eu.citrix.com> wrote:
> --- a/xen/arch/x86/domain.c	Thu May 27 09:39:47 2010 +0100
> +++ b/xen/arch/x86/domain.c	Fri May 28 15:42:28 2010 +0100
> @@ -1315,7 +1315,9 @@
>          return;
>  
>  #ifdef CONFIG_COMPAT
> -    if ( is_pv_32on64_domain(v->domain) )
> +    if ( is_pv_32on64_domain(v->domain) ||
> +         (is_hvm_pv_evtchn_domain(v->domain) &&
> +          has_32bit_shinfo(v->domain)) )
>      {
>          struct compat_vcpu_runstate_info info;

Is there any reason why this cannot be just has_32bit_shinfo()?

Jan

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] xen: update_runstate_area for 32 bit  PV on HVM guests
  2010-05-28 14:54 ` Jan Beulich
@ 2010-05-28 15:01   ` Stefano Stabellini
  2010-06-01  5:46     ` Keir Fraser
  0 siblings, 1 reply; 4+ messages in thread
From: Stefano Stabellini @ 2010-05-28 15:01 UTC (permalink / raw)
  To: Jan Beulich; +Cc: xen-devel, Stefano Stabellini

On Fri, 28 May 2010, Jan Beulich wrote:
> >>> On 28.05.10 at 16:45, Stefano Stabellini <stefano.stabellini@eu.citrix.com> wrote:
> > --- a/xen/arch/x86/domain.c	Thu May 27 09:39:47 2010 +0100
> > +++ b/xen/arch/x86/domain.c	Fri May 28 15:42:28 2010 +0100
> > @@ -1315,7 +1315,9 @@
> >          return;
> >  
> >  #ifdef CONFIG_COMPAT
> > -    if ( is_pv_32on64_domain(v->domain) )
> > +    if ( is_pv_32on64_domain(v->domain) ||
> > +         (is_hvm_pv_evtchn_domain(v->domain) &&
> > +          has_32bit_shinfo(v->domain)) )
> >      {
> >          struct compat_vcpu_runstate_info info;
> 
> Is there any reason why this cannot be just has_32bit_shinfo()?
> 
 
no, actually has_32bit_shinfo should be able to cover all cases

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] xen: update_runstate_area for 32 bit  PV on HVM guests
  2010-05-28 15:01   ` Stefano Stabellini
@ 2010-06-01  5:46     ` Keir Fraser
  0 siblings, 0 replies; 4+ messages in thread
From: Keir Fraser @ 2010-06-01  5:46 UTC (permalink / raw)
  To: Stefano Stabellini, Jan Beulich; +Cc: xen-devel

On 28/05/2010 16:01, "Stefano Stabellini" <Stefano.Stabellini@eu.citrix.com>
wrote:

>>>  #ifdef CONFIG_COMPAT
>>> -    if ( is_pv_32on64_domain(v->domain) )
>>> +    if ( is_pv_32on64_domain(v->domain) ||
>>> +         (is_hvm_pv_evtchn_domain(v->domain) &&
>>> +          has_32bit_shinfo(v->domain)) )
>>>      {
>>>          struct compat_vcpu_runstate_info info;
>> 
>> Is there any reason why this cannot be just has_32bit_shinfo()?
>> 
>  
> no, actually has_32bit_shinfo should be able to cover all cases

Xen-unstable:21493

 -- Keir

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2010-06-01  5:46 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-05-28 14:45 [PATCH] xen: update_runstate_area for 32 bit PV on HVM guests Stefano Stabellini
2010-05-28 14:54 ` Jan Beulich
2010-05-28 15:01   ` Stefano Stabellini
2010-06-01  5:46     ` Keir Fraser

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.