aboutsummaryrefslogtreecommitdiffstats
path: root/xen/arch/x86/hvm/vmsi.c
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2008-10-09 11:14:52 +0100
committerKeir Fraser <keir.fraser@citrix.com>2008-10-09 11:14:52 +0100
commitcdb9a3d55985ae317f78f147dd3af5c02c564caf (patch)
tree139075c762de9af2e7346145118c0117c1eac1fb /xen/arch/x86/hvm/vmsi.c
parent7ae8a1e482744619d6f4b93d67a044523099eae7 (diff)
downloadxen-cdb9a3d55985ae317f78f147dd3af5c02c564caf.tar.gz
xen-cdb9a3d55985ae317f78f147dd3af5c02c564caf.tar.bz2
xen-cdb9a3d55985ae317f78f147dd3af5c02c564caf.zip
Fix lock issue for hvm pass-through domain
This patch protect the hvm_irq_dpci structure with evtchn_lock, thus the access to domain's pirq_vector mapping is also protected. Signed-off-by: Jiang, Yunhong <yunhong.jiang@intel.com>
Diffstat (limited to 'xen/arch/x86/hvm/vmsi.c')
-rw-r--r--xen/arch/x86/hvm/vmsi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/xen/arch/x86/hvm/vmsi.c b/xen/arch/x86/hvm/vmsi.c
index d6ad008f4a..6eefb61bfa 100644
--- a/xen/arch/x86/hvm/vmsi.c
+++ b/xen/arch/x86/hvm/vmsi.c
@@ -134,7 +134,7 @@ int vmsi_deliver(struct domain *d, int pirq)
"vector=%x trig_mode=%x\n",
dest, dest_mode, delivery_mode, vector, trig_mode);
- if ( !(hvm_irq_dpci->mirq[pirq].flags & HVM_IRQ_DPCI_MSI) )
+ if ( !test_bit(_HVM_IRQ_DPCI_MSI, &hvm_irq_dpci->mirq[pirq].flags) )
{
gdprintk(XENLOG_WARNING, "pirq %x not msi \n", pirq);
return 0;