All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v1] vmx: set 'SN' bit for the runstate transition from blocked to runnable
@ 2017-04-13  2:20 Xuquan (Quan Xu)
  2017-04-12 19:35 ` Chao Gao
  0 siblings, 1 reply; 4+ messages in thread
From: Xuquan (Quan Xu) @ 2017-04-13  2:20 UTC (permalink / raw)
  To: xen-devel; +Cc: Andrew Cooper, Kevin Tian, Jun Nakajima, Jan Beulich, Chao Gao

[-- Attachment #1: Type: text/plain, Size: 1032 bytes --]

>From 946e7589e5a875574c7567a91943d47c38218a6f Mon Sep 17 00:00:00 2001
From: Quan Xu <xuquan8@huawei.com>
Date: Fri, 14 Apr 2017 02:11:30 +0800
Subject: [PATCH v1] vmx: set 'SN' bit for the runstate transition from blocked
 to runnable

set 'SN' bit of posted-interrupt descriptor when the runstate transition
is from blocked to runnable (SN bit of posted-interrupt descriptor is still
set to a blocked vCPU), otherwise PI notification event may be sent to a
non-running vCPU.

Signed-off-by: Quan Xu <xuquan8@huawei.com>
---
 xen/arch/x86/hvm/vmx/vmx.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/xen/arch/x86/hvm/vmx/vmx.c b/xen/arch/x86/hvm/vmx/vmx.c
index 9c5a388..956f104 100644
--- a/xen/arch/x86/hvm/vmx/vmx.c
+++ b/xen/arch/x86/hvm/vmx/vmx.c
@@ -142,9 +142,6 @@ static void vmx_pi_switch_from(struct vcpu *v)
 {
     struct pi_desc *pi_desc = &v->arch.hvm_vmx.pi_desc;

-    if ( test_bit(_VPF_blocked, &v->pause_flags) )
-        return;
-
     pi_set_sn(pi_desc);
 }

--
1.8.3.1

[-- Attachment #2: 0001-vmx-set-SN-bit-for-the-runstate-transition-from-bloc.patch --]
[-- Type: application/octet-stream, Size: 1003 bytes --]

From 946e7589e5a875574c7567a91943d47c38218a6f Mon Sep 17 00:00:00 2001
From: Quan Xu <xuquan8@huawei.com>
Date: Fri, 14 Apr 2017 02:11:30 +0800
Subject: [PATCH v1] vmx: set 'SN' bit for the runstate transition from blocked
 to runnable

set 'SN' bit of posted-interrupt descriptor when the runstate transition
is from blocked to runnable (SN bit of posted-interrupt descriptor is still
set to a blocked vCPU), otherwise PI notification event may be sent to a
non-running vCPU.

Signed-off-by: Quan Xu <xuquan8@huawei.com>
---
 xen/arch/x86/hvm/vmx/vmx.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/xen/arch/x86/hvm/vmx/vmx.c b/xen/arch/x86/hvm/vmx/vmx.c
index 9c5a388..956f104 100644
--- a/xen/arch/x86/hvm/vmx/vmx.c
+++ b/xen/arch/x86/hvm/vmx/vmx.c
@@ -142,9 +142,6 @@ static void vmx_pi_switch_from(struct vcpu *v)
 {
     struct pi_desc *pi_desc = &v->arch.hvm_vmx.pi_desc;
 
-    if ( test_bit(_VPF_blocked, &v->pause_flags) )
-        return;
-
     pi_set_sn(pi_desc);
 }
 
-- 
1.8.3.1


[-- Attachment #3: Type: text/plain, Size: 127 bytes --]

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

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

end of thread, other threads:[~2017-04-13 12:35 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-04-13  2:20 [PATCH v1] vmx: set 'SN' bit for the runstate transition from blocked to runnable Xuquan (Quan Xu)
2017-04-12 19:35 ` Chao Gao
2017-04-13  3:44   ` Xuquan (Quan Xu)
2017-04-13 12:35   ` Xuquan (Quan Xu)

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.