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-devel

[Xen-devel] [PATCH 6/9] In xen-pcifront.c updated printk(KERN_ERR ... to

Added much more verbose information to aid in troubleshooting
in the field.

Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx>
---
 drivers/pci/xen-pcifront.c |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/drivers/pci/xen-pcifront.c b/drivers/pci/xen-pcifront.c
index 1120034..ca95b23 100644
--- a/drivers/pci/xen-pcifront.c
+++ b/drivers/pci/xen-pcifront.c
@@ -273,7 +273,8 @@ int pci_frontend_enable_msix(struct pci_dev *dev,
        struct msi_desc *entry;
 
        if (nvec > SH_INFO_MAX_VEC) {
-               printk(KERN_ERR "too much vector for pci frontend%x\n", nvec);
+               dev_err(&dev->dev, "too much vector for pci frontend: %x."
+                                  " Increase SH_INFO_MAX_VEC.\n", nvec);
                return -EINVAL;
        }
 
@@ -299,7 +300,7 @@ int pci_frontend_enable_msix(struct pci_dev *dev,
                        return op.value;
                }
        } else {
-               printk(KERN_ERR "enable msix get err %x\n", err);
+               dev_err(&dev->dev, "enable msix get err %x\n", err);
                return err;
        }
 }
@@ -321,7 +322,7 @@ void pci_frontend_disable_msix(struct pci_dev *dev)
 
        /* What should do for error ? */
        if (err)
-               printk(KERN_ERR "pci_disable_msix get err %x\n", err);
+               dev_err(&dev->dev, "pci_disable_msix get err %x\n", err);
 }
 EXPORT_SYMBOL_GPL(pci_frontend_disable_msix);
 
@@ -341,8 +342,8 @@ int pci_frontend_enable_msi(struct pci_dev *dev, int 
**vector)
        if (likely(!err)) {
                *vector[0] = op.value;
        } else {
-               printk(KERN_ERR "pci frontend enable msi failed for dev %x:%x 
\n",
-                               op.bus, op.devfn);
+               dev_err(&dev->dev, "pci frontend enable msi failed for dev "
+                                  "%x:%x \n", op.bus, op.devfn);
                err = -EINVAL;
        }
        return err;
-- 
1.6.2.5


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