]> xenbits.xensource.com Git - xen.git/commitdiff
iommu: clear the iommu_* variables to 0 when iommu is not enabled.
authorKeir Fraser <keir.fraser@citrix.com>
Thu, 11 Mar 2010 08:09:58 +0000 (08:09 +0000)
committerKeir Fraser <keir.fraser@citrix.com>
Thu, 11 Mar 2010 08:09:58 +0000 (08:09 +0000)
With "iommu=0" xen parameter, the 3 iommu_* variables are still left
to the default value 1 -- this is misleading...

Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
xen/drivers/passthrough/iommu.c

index 702d81afe97d7838a1c56b54565c41d74528e6e1..ad988b2bcb20beb6f795e0f9490cba74f0ac1761 100644 (file)
@@ -288,7 +288,12 @@ int iommu_setup(void)
         panic("IOMMU setup failed, crash Xen for security purpose!\n");
 
     if ( !iommu_enabled )
+    {
         iommu_pv_enabled = 0;
+        iommu_snoop = 0;
+        iommu_qinval = 0;
+        iommu_intremap = 0;
+    }
     printk("I/O virtualisation %sabled\n", iommu_enabled ? "en" : "dis");
     if ( iommu_enabled )
         printk("I/O virtualisation for PV guests %sabled\n",