WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-3.4-testing] Even 'dummy' domains (e.g., dom_xen a.

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-3.4-testing] Even 'dummy' domains (e.g., dom_xen a.k.a. DOMID_XEN) must have valid I/O caps.
From: "Xen patchbot-3.4-testing" <patchbot-3.4-testing@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 14 May 2010 00:42:18 -0700
Delivery-date: Fri, 14 May 2010 00:49:56 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1273743619 -3600
# Node ID d11bdc25b36d1c852117d308fe70db461f5dabe8
# Parent  0d699edcd3d476a0a6ee28848cf13ceba4726441
Even 'dummy' domains (e.g., dom_xen a.k.a. DOMID_XEN) must have valid I/O caps.

Ensure the rangesets are always initialised. Certain (privileged)
invocations of hypercalls such as mmu_update can end up interrogating
these special domains for possible I/O capabilities.

Signed-off-by: Keir Fraser <keir.fraser@xxxxxxxxxx>
xen-unstable changeset:   21373:1ec412805622
xen-unstable date:        Thu May 13 10:09:02 2010 +0100
---
 xen/common/domain.c |   48 ++++++++++++++++++++++++------------------------
 1 files changed, 24 insertions(+), 24 deletions(-)

diff -r 0d699edcd3d4 -r d11bdc25b36d xen/common/domain.c
--- a/xen/common/domain.c       Thu May 13 10:38:59 2010 +0100
+++ b/xen/common/domain.c       Thu May 13 10:40:19 2010 +0100
@@ -229,37 +229,37 @@ struct domain *domain_create(
     if ( (domid == 0) && opt_dom0_vcpus_pin )
         d->is_pinned = 1;
 
-    if ( domcr_flags & DOMCRF_dummy )
-        return d;
-
     rangeset_domain_initialise(d);
     init_status |= INIT_rangeset;
-
-    if ( !is_idle_domain(d) )
-    {
-        if ( xsm_domain_create(d, ssidref) != 0 )
-            goto fail;
-
-        d->is_paused_by_controller = 1;
-        atomic_inc(&d->pause_count);
-
-        if ( evtchn_init(d) != 0 )
-            goto fail;
-        init_status |= INIT_evtchn;
-
-        if ( grant_table_create(d) != 0 )
-            goto fail;
-        init_status |= INIT_gnttab;
-    }
-
-    if ( arch_domain_create(d, domcr_flags) != 0 )
-        goto fail;
-    init_status |= INIT_arch;
 
     d->iomem_caps = rangeset_new(d, "I/O Memory", RANGESETF_prettyprint_hex);
     d->irq_caps   = rangeset_new(d, "Interrupts", 0);
     if ( (d->iomem_caps == NULL) || (d->irq_caps == NULL) )
         goto fail;
+
+    if ( domcr_flags & DOMCRF_dummy )
+        return d;
+
+    if ( !is_idle_domain(d) )
+    {
+        if ( xsm_domain_create(d, ssidref) != 0 )
+            goto fail;
+
+        d->is_paused_by_controller = 1;
+        atomic_inc(&d->pause_count);
+
+        if ( evtchn_init(d) != 0 )
+            goto fail;
+        init_status |= INIT_evtchn;
+
+        if ( grant_table_create(d) != 0 )
+            goto fail;
+        init_status |= INIT_gnttab;
+    }
+
+    if ( arch_domain_create(d, domcr_flags) != 0 )
+        goto fail;
+    init_status |= INIT_arch;
 
     if ( sched_init_domain(d) != 0 )
         goto fail;

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-3.4-testing] Even 'dummy' domains (e.g., dom_xen a.k.a. DOMID_XEN) must have valid I/O caps., Xen patchbot-3.4-testing <=