vtd: correct loglevel when check group devices
authorTiejun Chen <tiejun.chen@intel.com>
Wed, 16 Sep 2015 09:20:54 +0000 (11:20 +0200)
committerJan Beulich <jbeulich@suse.com>
Wed, 16 Sep 2015 09:20:54 +0000 (11:20 +0200)
Since commit 3848058e7dd6 (vtd/iommu: permit group devices to
passthrough in relaxed mode) is introduced, we always print
message as XENLOG_G_WARNING but its not correct in the case of
strict mode. So here is making this message depending on the
specific mode.

Signed-off-by: Tiejun Chen <tiejun.chen@intel.com>
Acked-by: Kevin Tian <kevin.tian@intel.com>
xen/drivers/passthrough/vtd/iommu.c

index 7b45bffebe2ae7950eac735f2f9f3e52129dfb44..b67b6244f8b4eeed23a90902c6d14fd825fc0e26 100644 (file)
@@ -2314,9 +2314,10 @@ static int intel_iommu_assign_device(
         {
             bool_t relaxed = !!(flag & XEN_DOMCTL_DEV_RDM_RELAXED);
 
-            printk(XENLOG_G_WARNING VTDPREFIX
+            printk(XENLOG_GUEST "%s" VTDPREFIX
                    " It's %s to assign %04x:%02x:%02x.%u"
                    " with shared RMRR at %"PRIx64" for Dom%d.\n",
+                   relaxed ? XENLOG_WARNING : XENLOG_ERR,
                    relaxed ? "risky" : "disallowed",
                    seg, bus, PCI_SLOT(devfn), PCI_FUNC(devfn),
                    rmrr->base_address, d->domain_id);