All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/4] Remove PVHv1 residuals
@ 2017-03-17 11:02 Wei Liu
  2017-03-17 11:02 ` [PATCH 1/4] docs: update dmop.markdown Wei Liu
                   ` (4 more replies)
  0 siblings, 5 replies; 20+ messages in thread
From: Wei Liu @ 2017-03-17 11:02 UTC (permalink / raw)
  To: Xen-devel; +Cc: Andrew Cooper, Wei Liu, Jan Beulich, Roger Pau Monné

Built on top my series to split dom0 builder.

Wei Liu (4):
  docs: update dmop.markdown
  sched.h: remove stale PVHv1 comment
  x86/traps: undo the PVHv1 bodge in NMI delivery path
  x86: remove stale PVHv1 comment from PV domain builder

 docs/designs/dmop.markdown   | 2 +-
 xen/arch/x86/pv/dom0_build.c | 4 ----
 xen/arch/x86/traps.c         | 2 +-
 xen/include/xen/sched.h      | 4 ----
 4 files changed, 2 insertions(+), 10 deletions(-)

-- 
2.11.0


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

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

* [PATCH 1/4] docs: update dmop.markdown
  2017-03-17 11:02 [PATCH 0/4] Remove PVHv1 residuals Wei Liu
@ 2017-03-17 11:02 ` Wei Liu
  2017-03-17 11:30   ` Paul Durrant
  2017-03-17 11:02 ` [PATCH 2/4] sched.h: remove stale PVHv1 comment Wei Liu
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 20+ messages in thread
From: Wei Liu @ 2017-03-17 11:02 UTC (permalink / raw)
  To: Xen-devel; +Cc: Andrew Cooper, Wei Liu, Jan Beulich, Roger Pau Monné

... to match the code after the removal of PVHv1.

Signed-off-by: Wei Liu <wei.liu2@citrix.com>
---
 docs/designs/dmop.markdown | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/docs/designs/dmop.markdown b/docs/designs/dmop.markdown
index a6cf6eb67b..8e9f95af47 100644
--- a/docs/designs/dmop.markdown
+++ b/docs/designs/dmop.markdown
@@ -128,7 +128,7 @@ static int dm_op(domid_t domid,
     if ( rc )
         return rc;
 
-    if ( !has_hvm_container_domain(d) )
+    if ( !is_hvm_domain(d) )
         goto out;
 
     rc = xsm_dm_op(XSM_DM_PRIV, d);
-- 
2.11.0


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

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

* [PATCH 2/4] sched.h: remove stale PVHv1 comment
  2017-03-17 11:02 [PATCH 0/4] Remove PVHv1 residuals Wei Liu
  2017-03-17 11:02 ` [PATCH 1/4] docs: update dmop.markdown Wei Liu
@ 2017-03-17 11:02 ` Wei Liu
  2017-03-17 11:02 ` [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path Wei Liu
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 20+ messages in thread
From: Wei Liu @ 2017-03-17 11:02 UTC (permalink / raw)
  To: Xen-devel; +Cc: Andrew Cooper, Wei Liu, Jan Beulich, Roger Pau Monné

With the removal of PVHv1 this comment is wrong. Just remove it.

Signed-off-by: Wei Liu <wei.liu2@citrix.com>
---
 xen/include/xen/sched.h | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/xen/include/xen/sched.h b/xen/include/xen/sched.h
index 832352a5ce..325733a4b8 100644
--- a/xen/include/xen/sched.h
+++ b/xen/include/xen/sched.h
@@ -307,10 +307,6 @@ struct vm_event_per_domain
 
 struct evtchn_port_ops;
 
-/*
- * PVH is a PV guest running in an HVM container.  is_hvm_* checks
- * will be false, but has_hvm_container_* checks will be true.
- */
 enum guest_type {
     guest_type_pv, guest_type_hvm
 };
-- 
2.11.0


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

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

* [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path
  2017-03-17 11:02 [PATCH 0/4] Remove PVHv1 residuals Wei Liu
  2017-03-17 11:02 ` [PATCH 1/4] docs: update dmop.markdown Wei Liu
  2017-03-17 11:02 ` [PATCH 2/4] sched.h: remove stale PVHv1 comment Wei Liu
@ 2017-03-17 11:02 ` Wei Liu
  2017-03-17 11:06   ` Andrew Cooper
  2017-03-17 11:02 ` [PATCH 4/4] x86: remove stale PVHv1 comment from PV domain builder Wei Liu
  2017-03-17 11:05 ` [PATCH 0/4] Remove PVHv1 residuals Jan Beulich
  4 siblings, 1 reply; 20+ messages in thread
From: Wei Liu @ 2017-03-17 11:02 UTC (permalink / raw)
  To: Xen-devel; +Cc: Andrew Cooper, Wei Liu, Jan Beulich, Roger Pau Monné

A bodge was added in 21c9fce8efb to skip delivering NMI to PVHv1 guest.
Now that PVHv1 is gone, undo that bodge and remove the fixme.

Signed-off-by: Wei Liu <wei.liu2@citrix.com>
---
 xen/arch/x86/traps.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/xen/arch/x86/traps.c b/xen/arch/x86/traps.c
index 0d54baf20e..c785b3f353 100644
--- a/xen/arch/x86/traps.c
+++ b/xen/arch/x86/traps.c
@@ -3537,7 +3537,7 @@ static void nmi_hwdom_report(unsigned int reason_idx)
 {
     struct domain *d = hardware_domain;
 
-    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) /* PVH fixme */ )
+    if ( !d || !d->vcpu || !d->vcpu[0] )
         return;
 
     set_bit(reason_idx, nmi_reason(d));
-- 
2.11.0


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

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

* [PATCH 4/4] x86: remove stale PVHv1 comment from PV domain builder
  2017-03-17 11:02 [PATCH 0/4] Remove PVHv1 residuals Wei Liu
                   ` (2 preceding siblings ...)
  2017-03-17 11:02 ` [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path Wei Liu
@ 2017-03-17 11:02 ` Wei Liu
  2017-03-17 11:05 ` [PATCH 0/4] Remove PVHv1 residuals Jan Beulich
  4 siblings, 0 replies; 20+ messages in thread
From: Wei Liu @ 2017-03-17 11:02 UTC (permalink / raw)
  To: Xen-devel; +Cc: Andrew Cooper, Wei Liu, Jan Beulich, Roger Pau Monné

Signed-off-by: Wei Liu <wei.liu2@citrix.com>
---
 xen/arch/x86/pv/dom0_build.c | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/xen/arch/x86/pv/dom0_build.c b/xen/arch/x86/pv/dom0_build.c
index bb82c33a4c..6872b30209 100644
--- a/xen/arch/x86/pv/dom0_build.c
+++ b/xen/arch/x86/pv/dom0_build.c
@@ -872,10 +872,6 @@ int __init dom0_construct_pv(
         paging_update_paging_modes(v);
 #endif
 
-    /*
-     * PVH Fixme: XENFEAT_supervisor_mode_kernel has been reused in PVH with a
-     * different meaning.
-     */
     if ( test_bit(XENFEAT_supervisor_mode_kernel, parms.f_required) )
         panic("Dom0 requires supervisor-mode execution");
 
-- 
2.11.0


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

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

* Re: [PATCH 0/4] Remove PVHv1 residuals
  2017-03-17 11:02 [PATCH 0/4] Remove PVHv1 residuals Wei Liu
                   ` (3 preceding siblings ...)
  2017-03-17 11:02 ` [PATCH 4/4] x86: remove stale PVHv1 comment from PV domain builder Wei Liu
@ 2017-03-17 11:05 ` Jan Beulich
  2017-03-17 11:07   ` Andrew Cooper
  4 siblings, 1 reply; 20+ messages in thread
From: Jan Beulich @ 2017-03-17 11:05 UTC (permalink / raw)
  To: Wei Liu; +Cc: Andrew Cooper, Xen-devel, Roger Pau Monné

>>> On 17.03.17 at 12:02, <wei.liu2@citrix.com> wrote:
> Built on top my series to split dom0 builder.
> 
> Wei Liu (4):
>   docs: update dmop.markdown
>   sched.h: remove stale PVHv1 comment
>   x86/traps: undo the PVHv1 bodge in NMI delivery path
>   x86: remove stale PVHv1 comment from PV domain builder

Acked-by: Jan Beulich <jbeulich@suse.com>



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

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

* Re: [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path
  2017-03-17 11:02 ` [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path Wei Liu
@ 2017-03-17 11:06   ` Andrew Cooper
  2017-03-17 11:10     ` Wei Liu
  0 siblings, 1 reply; 20+ messages in thread
From: Andrew Cooper @ 2017-03-17 11:06 UTC (permalink / raw)
  To: Wei Liu, Xen-devel; +Cc: Jan Beulich, Roger Pau Monné

On 17/03/17 11:02, Wei Liu wrote:
> A bodge was added in 21c9fce8efb to skip delivering NMI to PVHv1 guest.
> Now that PVHv1 is gone, undo that bodge and remove the fixme.
>
> Signed-off-by: Wei Liu <wei.liu2@citrix.com>

This unfortunately needs to stay, although perhaps it wants rewording.

send_guest_trap() just out of context below is PV-specific, making this
path unsuitable for any HVM guests.

~Andrew

> ---
>  xen/arch/x86/traps.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/xen/arch/x86/traps.c b/xen/arch/x86/traps.c
> index 0d54baf20e..c785b3f353 100644
> --- a/xen/arch/x86/traps.c
> +++ b/xen/arch/x86/traps.c
> @@ -3537,7 +3537,7 @@ static void nmi_hwdom_report(unsigned int reason_idx)
>  {
>      struct domain *d = hardware_domain;
>  
> -    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) /* PVH fixme */ )
> +    if ( !d || !d->vcpu || !d->vcpu[0] )
>          return;
>  
>      set_bit(reason_idx, nmi_reason(d));


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

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

* Re: [PATCH 0/4] Remove PVHv1 residuals
  2017-03-17 11:05 ` [PATCH 0/4] Remove PVHv1 residuals Jan Beulich
@ 2017-03-17 11:07   ` Andrew Cooper
  0 siblings, 0 replies; 20+ messages in thread
From: Andrew Cooper @ 2017-03-17 11:07 UTC (permalink / raw)
  To: Jan Beulich, Wei Liu; +Cc: Xen-devel, Roger Pau Monné

On 17/03/17 11:05, Jan Beulich wrote:
>>>> On 17.03.17 at 12:02, <wei.liu2@citrix.com> wrote:
>> Built on top my series to split dom0 builder.
>>
>> Wei Liu (4):
>>   docs: update dmop.markdown
>>   sched.h: remove stale PVHv1 comment
>>   x86/traps: undo the PVHv1 bodge in NMI delivery path
>>   x86: remove stale PVHv1 comment from PV domain builder
> Acked-by: Jan Beulich <jbeulich@suse.com>
>
>

1, 2 and 4

Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>

Patch 3 needs further work.

~Andrew

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

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

* Re: [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path
  2017-03-17 11:06   ` Andrew Cooper
@ 2017-03-17 11:10     ` Wei Liu
  2017-03-17 11:11       ` Andrew Cooper
  2017-03-17 11:22       ` Roger Pau Monné
  0 siblings, 2 replies; 20+ messages in thread
From: Wei Liu @ 2017-03-17 11:10 UTC (permalink / raw)
  To: Andrew Cooper; +Cc: Xen-devel, Wei Liu, Jan Beulich, Roger Pau Monné

On Fri, Mar 17, 2017 at 11:06:41AM +0000, Andrew Cooper wrote:
> On 17/03/17 11:02, Wei Liu wrote:
> > A bodge was added in 21c9fce8efb to skip delivering NMI to PVHv1 guest.
> > Now that PVHv1 is gone, undo that bodge and remove the fixme.
> >
> > Signed-off-by: Wei Liu <wei.liu2@citrix.com>
> 
> This unfortunately needs to stay, although perhaps it wants rewording.
> 
> send_guest_trap() just out of context below is PV-specific, making this
> path unsuitable for any HVM guests.
> 

Just removing the comment should be fine then.

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

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

* Re: [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path
  2017-03-17 11:10     ` Wei Liu
@ 2017-03-17 11:11       ` Andrew Cooper
  2017-03-17 11:14         ` Wei Liu
  2017-03-17 11:22       ` Roger Pau Monné
  1 sibling, 1 reply; 20+ messages in thread
From: Andrew Cooper @ 2017-03-17 11:11 UTC (permalink / raw)
  To: Wei Liu; +Cc: Xen-devel, Jan Beulich, Roger Pau Monné

On 17/03/17 11:10, Wei Liu wrote:
> On Fri, Mar 17, 2017 at 11:06:41AM +0000, Andrew Cooper wrote:
>> On 17/03/17 11:02, Wei Liu wrote:
>>> A bodge was added in 21c9fce8efb to skip delivering NMI to PVHv1 guest.
>>> Now that PVHv1 is gone, undo that bodge and remove the fixme.
>>>
>>> Signed-off-by: Wei Liu <wei.liu2@citrix.com>
>> This unfortunately needs to stay, although perhaps it wants rewording.
>>
>> send_guest_trap() just out of context below is PV-specific, making this
>> path unsuitable for any HVM guests.
>>
> Just removing the comment should be fine then.

Ok then.

~Andrew

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

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

* Re: [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path
  2017-03-17 11:11       ` Andrew Cooper
@ 2017-03-17 11:14         ` Wei Liu
  2017-03-17 11:26           ` Jan Beulich
  0 siblings, 1 reply; 20+ messages in thread
From: Wei Liu @ 2017-03-17 11:14 UTC (permalink / raw)
  To: Andrew Cooper; +Cc: Xen-devel, Wei Liu, Jan Beulich, Roger Pau Monné

On Fri, Mar 17, 2017 at 11:11:17AM +0000, Andrew Cooper wrote:
> On 17/03/17 11:10, Wei Liu wrote:
> > On Fri, Mar 17, 2017 at 11:06:41AM +0000, Andrew Cooper wrote:
> >> On 17/03/17 11:02, Wei Liu wrote:
> >>> A bodge was added in 21c9fce8efb to skip delivering NMI to PVHv1 guest.
> >>> Now that PVHv1 is gone, undo that bodge and remove the fixme.
> >>>
> >>> Signed-off-by: Wei Liu <wei.liu2@citrix.com>
> >> This unfortunately needs to stay, although perhaps it wants rewording.
> >>
> >> send_guest_trap() just out of context below is PV-specific, making this
> >> path unsuitable for any HVM guests.
> >>
> > Just removing the comment should be fine then.
> 
> Ok then.


From 3f4e56ed1990926ce642317093dd7e24a47f2647 Mon Sep 17 00:00:00 2001
From: Wei Liu <wei.liu2@citrix.com>
Date: Thu, 16 Mar 2017 19:11:56 +0000
Subject: [PATCH] x86/traps: remove PVH fixme in NMI delivery path

A bodge was added in 21c9fce8efb to skip delivering NMI to PVHv1 guest.
Although PVHv1 is gone, the check for PV domain is still needed as this
function is PV specific.

Just remove the PVH fixme comment.

Signed-off-by: Wei Liu <wei.liu2@citrix.com>
---
 xen/arch/x86/traps.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/xen/arch/x86/traps.c b/xen/arch/x86/traps.c
index 0d54baf20e..c51e9cc2cc 100644
--- a/xen/arch/x86/traps.c
+++ b/xen/arch/x86/traps.c
@@ -3537,7 +3537,7 @@ static void nmi_hwdom_report(unsigned int reason_idx)
 {
     struct domain *d = hardware_domain;
 
-    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) /* PVH fixme */ )
+    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) )
         return;
 
     set_bit(reason_idx, nmi_reason(d));
-- 
2.11.0


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

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

* Re: [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path
  2017-03-17 11:10     ` Wei Liu
  2017-03-17 11:11       ` Andrew Cooper
@ 2017-03-17 11:22       ` Roger Pau Monné
  1 sibling, 0 replies; 20+ messages in thread
From: Roger Pau Monné @ 2017-03-17 11:22 UTC (permalink / raw)
  To: Wei Liu; +Cc: Andrew Cooper, Jan Beulich, Xen-devel

On Fri, Mar 17, 2017 at 11:10:19AM +0000, Wei Liu wrote:
> On Fri, Mar 17, 2017 at 11:06:41AM +0000, Andrew Cooper wrote:
> > On 17/03/17 11:02, Wei Liu wrote:
> > > A bodge was added in 21c9fce8efb to skip delivering NMI to PVHv1 guest.
> > > Now that PVHv1 is gone, undo that bodge and remove the fixme.
> > >
> > > Signed-off-by: Wei Liu <wei.liu2@citrix.com>
> > 
> > This unfortunately needs to stay, although perhaps it wants rewording.
> > 
> > send_guest_trap() just out of context below is PV-specific, making this
> > path unsuitable for any HVM guests.
> > 
> 
> Just removing the comment should be fine then.

This has reminded me that I should send a patch to prevent using nmi=dom0 with
dom0=pvh.

Roger.

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

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

* Re: [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path
  2017-03-17 11:14         ` Wei Liu
@ 2017-03-17 11:26           ` Jan Beulich
  2017-03-17 11:29             ` Wei Liu
  0 siblings, 1 reply; 20+ messages in thread
From: Jan Beulich @ 2017-03-17 11:26 UTC (permalink / raw)
  To: Wei Liu; +Cc: Andrew Cooper, Xen-devel, Roger Pau Monné

>>> On 17.03.17 at 12:14, <wei.liu2@citrix.com> wrote:
> --- a/xen/arch/x86/traps.c
> +++ b/xen/arch/x86/traps.c
> @@ -3537,7 +3537,7 @@ static void nmi_hwdom_report(unsigned int reason_idx)
>  {
>      struct domain *d = hardware_domain;
>  
> -    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) /* PVH fixme */ )
> +    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) )
>          return;

But why would you remove the comment then? This needs fixing,
after all.


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

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

* Re: [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path
  2017-03-17 11:26           ` Jan Beulich
@ 2017-03-17 11:29             ` Wei Liu
  2017-03-17 11:31               ` Andrew Cooper
  2017-03-17 11:35               ` Roger Pau Monné
  0 siblings, 2 replies; 20+ messages in thread
From: Wei Liu @ 2017-03-17 11:29 UTC (permalink / raw)
  To: Jan Beulich; +Cc: Andrew Cooper, Wei Liu, Xen-devel, Roger Pau Monné

On Fri, Mar 17, 2017 at 05:26:07AM -0600, Jan Beulich wrote:
> >>> On 17.03.17 at 12:14, <wei.liu2@citrix.com> wrote:
> > --- a/xen/arch/x86/traps.c
> > +++ b/xen/arch/x86/traps.c
> > @@ -3537,7 +3537,7 @@ static void nmi_hwdom_report(unsigned int reason_idx)
> >  {
> >      struct domain *d = hardware_domain;
> >  
> > -    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) /* PVH fixme */ )
> > +    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) )
> >          return;
> 
> But why would you remove the comment then? This needs fixing,
> after all.
> 

Isn't PVHv2 going to use the native path? Now that there is no PVHv1,
what is there to fix?

Wei.

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

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

* Re: [PATCH 1/4] docs: update dmop.markdown
  2017-03-17 11:02 ` [PATCH 1/4] docs: update dmop.markdown Wei Liu
@ 2017-03-17 11:30   ` Paul Durrant
  2017-03-17 11:32     ` Andrew Cooper
  0 siblings, 1 reply; 20+ messages in thread
From: Paul Durrant @ 2017-03-17 11:30 UTC (permalink / raw)
  To: Xen-devel; +Cc: Andrew Cooper, Wei Liu, Jan Beulich, Roger Pau Monne

> -----Original Message-----
> From: Xen-devel [mailto:xen-devel-bounces@lists.xen.org] On Behalf Of
> Wei Liu
> Sent: 17 March 2017 11:02
> To: Xen-devel <xen-devel@lists.xenproject.org>
> Cc: Andrew Cooper <Andrew.Cooper3@citrix.com>; Wei Liu
> <wei.liu2@citrix.com>; Jan Beulich <JBeulich@suse.com>; Roger Pau Monne
> <roger.pau@citrix.com>
> Subject: [Xen-devel] [PATCH 1/4] docs: update dmop.markdown
> 
> ... to match the code after the removal of PVHv1.
> 
> Signed-off-by: Wei Liu <wei.liu2@citrix.com>

Reviewed-by: Paul Durrant <paul.durrant@citrix.com>

> ---
>  docs/designs/dmop.markdown | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/docs/designs/dmop.markdown b/docs/designs/dmop.markdown
> index a6cf6eb67b..8e9f95af47 100644
> --- a/docs/designs/dmop.markdown
> +++ b/docs/designs/dmop.markdown
> @@ -128,7 +128,7 @@ static int dm_op(domid_t domid,
>      if ( rc )
>          return rc;
> 
> -    if ( !has_hvm_container_domain(d) )
> +    if ( !is_hvm_domain(d) )
>          goto out;
> 
>      rc = xsm_dm_op(XSM_DM_PRIV, d);
> --
> 2.11.0
> 
> 
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xen.org
> https://lists.xen.org/xen-devel
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

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

* Re: [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path
  2017-03-17 11:29             ` Wei Liu
@ 2017-03-17 11:31               ` Andrew Cooper
  2017-03-17 11:34                 ` Wei Liu
  2017-03-17 11:35               ` Roger Pau Monné
  1 sibling, 1 reply; 20+ messages in thread
From: Andrew Cooper @ 2017-03-17 11:31 UTC (permalink / raw)
  To: Wei Liu, Jan Beulich; +Cc: Xen-devel, Roger Pau Monné

On 17/03/17 11:29, Wei Liu wrote:
> On Fri, Mar 17, 2017 at 05:26:07AM -0600, Jan Beulich wrote:
>>>>> On 17.03.17 at 12:14, <wei.liu2@citrix.com> wrote:
>>> --- a/xen/arch/x86/traps.c
>>> +++ b/xen/arch/x86/traps.c
>>> @@ -3537,7 +3537,7 @@ static void nmi_hwdom_report(unsigned int reason_idx)
>>>  {
>>>      struct domain *d = hardware_domain;
>>>  
>>> -    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) /* PVH fixme */ )
>>> +    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) )
>>>          return;
>> But why would you remove the comment then? This needs fixing,
>> after all.
>>
> Isn't PVHv2 going to use the native path? Now that there is no PVHv1,
> what is there to fix?

The native "inject an NMI" path still needs wiring into this codepath. 
The reason it wasn't done for PVHv1 was because we don't have a suitable
native path yet, iirc.

~Andrew

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

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

* Re: [PATCH 1/4] docs: update dmop.markdown
  2017-03-17 11:30   ` Paul Durrant
@ 2017-03-17 11:32     ` Andrew Cooper
  2017-03-17 11:40       ` Paul Durrant
  0 siblings, 1 reply; 20+ messages in thread
From: Andrew Cooper @ 2017-03-17 11:32 UTC (permalink / raw)
  To: Paul Durrant, Wei Liu, Xen-devel; +Cc: Jan Beulich, Roger Pau Monne

On 17/03/17 11:30, Paul Durrant wrote:
>> -----Original Message-----
>> From: Xen-devel [mailto:xen-devel-bounces@lists.xen.org] On Behalf Of
>> Wei Liu
>> Sent: 17 March 2017 11:02
>> To: Xen-devel <xen-devel@lists.xenproject.org>
>> Cc: Andrew Cooper <Andrew.Cooper3@citrix.com>; Wei Liu
>> <wei.liu2@citrix.com>; Jan Beulich <JBeulich@suse.com>; Roger Pau Monne
>> <roger.pau@citrix.com>
>> Subject: [Xen-devel] [PATCH 1/4] docs: update dmop.markdown
>>
>> ... to match the code after the removal of PVHv1.
>>
>> Signed-off-by: Wei Liu <wei.liu2@citrix.com>
> Reviewed-by: Paul Durrant <paul.durrant@citrix.com>

As an observation, why do we have C in a design doc like this?

~Andrew

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

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

* Re: [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path
  2017-03-17 11:31               ` Andrew Cooper
@ 2017-03-17 11:34                 ` Wei Liu
  0 siblings, 0 replies; 20+ messages in thread
From: Wei Liu @ 2017-03-17 11:34 UTC (permalink / raw)
  To: Andrew Cooper; +Cc: Xen-devel, Wei Liu, Jan Beulich, Roger Pau Monné

On Fri, Mar 17, 2017 at 11:31:45AM +0000, Andrew Cooper wrote:
> On 17/03/17 11:29, Wei Liu wrote:
> > On Fri, Mar 17, 2017 at 05:26:07AM -0600, Jan Beulich wrote:
> >>>>> On 17.03.17 at 12:14, <wei.liu2@citrix.com> wrote:
> >>> --- a/xen/arch/x86/traps.c
> >>> +++ b/xen/arch/x86/traps.c
> >>> @@ -3537,7 +3537,7 @@ static void nmi_hwdom_report(unsigned int reason_idx)
> >>>  {
> >>>      struct domain *d = hardware_domain;
> >>>  
> >>> -    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) /* PVH fixme */ )
> >>> +    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) )
> >>>          return;
> >> But why would you remove the comment then? This needs fixing,
> >> after all.
> >>
> > Isn't PVHv2 going to use the native path? Now that there is no PVHv1,
> > what is there to fix?
> 
> The native "inject an NMI" path still needs wiring into this codepath. 
> The reason it wasn't done for PVHv1 was because we don't have a suitable
> native path yet, iirc.
> 

OK, in that case dropping this patch is the most appropriate action.

Wei.

> ~Andrew

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

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

* Re: [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path
  2017-03-17 11:29             ` Wei Liu
  2017-03-17 11:31               ` Andrew Cooper
@ 2017-03-17 11:35               ` Roger Pau Monné
  1 sibling, 0 replies; 20+ messages in thread
From: Roger Pau Monné @ 2017-03-17 11:35 UTC (permalink / raw)
  To: Wei Liu; +Cc: Andrew Cooper, Jan Beulich, Xen-devel

On Fri, Mar 17, 2017 at 11:29:38AM +0000, Wei Liu wrote:
> On Fri, Mar 17, 2017 at 05:26:07AM -0600, Jan Beulich wrote:
> > >>> On 17.03.17 at 12:14, <wei.liu2@citrix.com> wrote:
> > > --- a/xen/arch/x86/traps.c
> > > +++ b/xen/arch/x86/traps.c
> > > @@ -3537,7 +3537,7 @@ static void nmi_hwdom_report(unsigned int reason_idx)
> > >  {
> > >      struct domain *d = hardware_domain;
> > >  
> > > -    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) /* PVH fixme */ )
> > > +    if ( !d || !d->vcpu || !d->vcpu[0] || !is_pv_domain(d) )
> > >          return;
> > 
> > But why would you remove the comment then? This needs fixing,
> > after all.
> > 
> 
> Isn't PVHv2 going to use the native path? Now that there is no PVHv1,
> what is there to fix?

The code in nmi_hwdom_report assumes that Dom0 is a PV guest, and injects a PV
NMI (or whatever it's called) by setting the reason in the shared info struct.
On PVHv2 we sould use the native (HVM) way of injecting NMIs IMHO.

Roger.

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

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

* Re: [PATCH 1/4] docs: update dmop.markdown
  2017-03-17 11:32     ` Andrew Cooper
@ 2017-03-17 11:40       ` Paul Durrant
  0 siblings, 0 replies; 20+ messages in thread
From: Paul Durrant @ 2017-03-17 11:40 UTC (permalink / raw)
  To: Andrew Cooper, Wei Liu, Xen-devel; +Cc: Jan Beulich, Roger Pau Monne

> -----Original Message-----
> From: Andrew Cooper
> Sent: 17 March 2017 11:33
> To: Paul Durrant <Paul.Durrant@citrix.com>; Wei Liu <wei.liu2@citrix.com>;
> Xen-devel <xen-devel@lists.xenproject.org>
> Cc: Jan Beulich <JBeulich@suse.com>; Roger Pau Monne
> <roger.pau@citrix.com>
> Subject: Re: [Xen-devel] [PATCH 1/4] docs: update dmop.markdown
> 
> On 17/03/17 11:30, Paul Durrant wrote:
> >> -----Original Message-----
> >> From: Xen-devel [mailto:xen-devel-bounces@lists.xen.org] On Behalf Of
> >> Wei Liu
> >> Sent: 17 March 2017 11:02
> >> To: Xen-devel <xen-devel@lists.xenproject.org>
> >> Cc: Andrew Cooper <Andrew.Cooper3@citrix.com>; Wei Liu
> >> <wei.liu2@citrix.com>; Jan Beulich <JBeulich@suse.com>; Roger Pau
> Monne
> >> <roger.pau@citrix.com>
> >> Subject: [Xen-devel] [PATCH 1/4] docs: update dmop.markdown
> >>
> >> ... to match the code after the removal of PVHv1.
> >>
> >> Signed-off-by: Wei Liu <wei.liu2@citrix.com>
> > Reviewed-by: Paul Durrant <paul.durrant@citrix.com>
> 
> As an observation, why do we have C in a design doc like this?
> 

It is there as an illustration of how the hypercall implementation is supposed to function. If you prefer pseudo code then I'd have no objection to a patch to change this.

  Paul 

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

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

end of thread, other threads:[~2017-03-17 11:40 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-03-17 11:02 [PATCH 0/4] Remove PVHv1 residuals Wei Liu
2017-03-17 11:02 ` [PATCH 1/4] docs: update dmop.markdown Wei Liu
2017-03-17 11:30   ` Paul Durrant
2017-03-17 11:32     ` Andrew Cooper
2017-03-17 11:40       ` Paul Durrant
2017-03-17 11:02 ` [PATCH 2/4] sched.h: remove stale PVHv1 comment Wei Liu
2017-03-17 11:02 ` [PATCH 3/4] x86/traps: undo the PVHv1 bodge in NMI delivery path Wei Liu
2017-03-17 11:06   ` Andrew Cooper
2017-03-17 11:10     ` Wei Liu
2017-03-17 11:11       ` Andrew Cooper
2017-03-17 11:14         ` Wei Liu
2017-03-17 11:26           ` Jan Beulich
2017-03-17 11:29             ` Wei Liu
2017-03-17 11:31               ` Andrew Cooper
2017-03-17 11:34                 ` Wei Liu
2017-03-17 11:35               ` Roger Pau Monné
2017-03-17 11:22       ` Roger Pau Monné
2017-03-17 11:02 ` [PATCH 4/4] x86: remove stale PVHv1 comment from PV domain builder Wei Liu
2017-03-17 11:05 ` [PATCH 0/4] Remove PVHv1 residuals Jan Beulich
2017-03-17 11:07   ` Andrew Cooper

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.