From: Daniel De Graaf Date: Tue, 8 Jan 2013 09:37:38 +0000 (+0100) Subject: x86/hvm: Bind xen-created event channels to building domain X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~7472 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=3c303591a61b0e0a8a9d5c067a112118850b54f8;p=xen.git x86/hvm: Bind xen-created event channels to building domain 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 Committed-by: Jan Beulich --- diff --git a/xen/arch/x86/hvm/hvm.c b/xen/arch/x86/hvm/hvm.c index 40c1ab219f..682d934c7e 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;