pass-through: drop pointless uses of __func__
authorJan Beulich <jbeulich@suse.com>
Mon, 29 Aug 2016 14:04:22 +0000 (16:04 +0200)
committerJan Beulich <jbeulich@suse.com>
Mon, 29 Aug 2016 14:04:22 +0000 (16:04 +0200)
Non-debugging message text should be (and is in the cases here)
distinguishable without also logging function names. Additionally log
the PCI device coordinates for alloc_pdev() failure.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
xen/drivers/passthrough/pci.c

index 8bce213374111ba2cdcf08fdcac7c39fe840d1a9..338d6b4f37105aae13aa44f9af4541d8163ad962 100644 (file)
@@ -379,8 +379,8 @@ static struct pci_dev *alloc_pdev(struct pci_seg *pseg, u8 bus, u8 devfn)
             break;
 
         default:
-            printk(XENLOG_WARNING "%s: unknown type: %04x:%02x:%02x.%u\n",
-                   __func__, pseg->nr, bus, PCI_SLOT(devfn), PCI_FUNC(devfn));
+            printk(XENLOG_WARNING "%04x:%02x:%02x.%u: unknown type %d\n",
+                   pseg->nr, bus, PCI_SLOT(devfn), PCI_FUNC(devfn), pdev->type);
             break;
     }
 
@@ -991,7 +991,8 @@ static int __init _scan_pci_devices(struct pci_seg *pseg, void *arg)
                 pdev = alloc_pdev(pseg, bus, PCI_DEVFN(dev, func));
                 if ( !pdev )
                 {
-                    printk("%s: alloc_pdev failed.\n", __func__);
+                    printk(XENLOG_WARNING "%04x:%02x:%02x.%u: alloc_pdev failed\n",
+                           pseg->nr, bus, dev, func);
                     return -ENOMEM;
                 }