xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] arch/x86/hvm: Bind xen-created event channels to building domain
@ 2013-01-03 18:28 Daniel De Graaf
  2013-01-09  8:51 ` Keir Fraser
  2013-01-09 11:12 ` Ian Campbell
  0 siblings, 2 replies; 10+ messages in thread
From: Daniel De Graaf @ 2013-01-03 18:28 UTC (permalink / raw)
  To: xen-devel; +Cc: Daniel De Graaf, Keir Fraser, Jan Beulich

Instead of using a hardcoded domain 0 as the endpoint for the event
channels created in hvm_vcpu_initialise, use the domain ID of the
building domain so that a domain builder in a domain other than dom0 has
the expected access to the event channels.

Signed-off-by: Daniel De Graaf <dgdegra@tycho.nsa.gov>
Cc: Keir Fraser <keir@xen.org>
Cc: Jan Beulich <jbeulich@suse.com>
---
 xen/arch/x86/hvm/hvm.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/xen/arch/x86/hvm/hvm.c b/xen/arch/x86/hvm/hvm.c
index 40c1ab2..682d934 100644
--- a/xen/arch/x86/hvm/hvm.c
+++ b/xen/arch/x86/hvm/hvm.c
@@ -1071,7 +1071,7 @@ int hvm_vcpu_initialise(struct vcpu *v)
         goto fail3;
 
     /* Create ioreq event channel. */
-    rc = alloc_unbound_xen_event_channel(v, 0, NULL);
+    rc = alloc_unbound_xen_event_channel(v, current->domain->domain_id, NULL);
     if ( rc < 0 )
         goto fail4;
 
@@ -1081,7 +1081,7 @@ int hvm_vcpu_initialise(struct vcpu *v)
     if ( v->vcpu_id == 0 )
     {
         /* Create bufioreq event channel. */
-        rc = alloc_unbound_xen_event_channel(v, 0, NULL);
+        rc = alloc_unbound_xen_event_channel(v, current->domain->domain_id, NULL);
         if ( rc < 0 )
             goto fail2;
         v->domain->arch.hvm_domain.params[HVM_PARAM_BUFIOREQ_EVTCHN] = rc;
-- 
1.7.11.7

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

end of thread, other threads:[~2013-01-09 16:24 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-03 18:28 [PATCH] arch/x86/hvm: Bind xen-created event channels to building domain Daniel De Graaf
2013-01-09  8:51 ` Keir Fraser
2013-01-09 10:27   ` Jan Beulich
2013-01-09 11:12 ` Ian Campbell
2013-01-09 14:43   ` Daniel De Graaf
2013-01-09 14:56     ` Ian Campbell
2013-01-09 15:30       ` Daniel De Graaf
2013-01-09 15:38         ` Keir Fraser
2013-01-09 16:24         ` Ian Campbell
2013-01-09 15:02     ` Keir Fraser

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).