aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/msi.c
diff options
context:
space:
mode:
authorBjorn Helgaas <bjorn.helgaas@hp.com>2008-06-13 12:52:11 -0400
committerJesse Barnes <jbarnes@virtuousgeek.org>2008-06-25 19:05:13 -0400
commit80ccba1186d48fa728dc4b1456cc07ffb07da501 (patch)
treeb58826b8d0e42e2a41e5f5632bf95e52f9dfc676 /drivers/pci/msi.c
parentb86ec7ed2877f560ff069e8ed1b433a9005619c6 (diff)
PCI: use dev_printk when possible
Convert printks to use dev_printk(). I converted pr_debug() to dev_dbg(). Both use KERN_DEBUG and are enabled only when DEBUG is defined. I converted printk(KERN_DEBUG) to dev_printk(KERN_DEBUG), not to dev_dbg(), because dev_dbg() is only enabled when DEBUG is defined. I converted DBG(KERN_INFO) (only in setup-bus.c) to dev_info(). The DBG() name makes it sound like debug, but it's been enabled forever, so dev_info() preserves the previous behavior. I tried to make the resource assignment formats more consistent, e.g., "BAR %d: got res [%#llx-%#llx] bus [%#llx-%#llx] flags %#lx\n" instead of sometimes using "start-end" and sometimes using "size@start". I'm not attached to one or the other; I'd just like them consistent. Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Diffstat (limited to 'drivers/pci/msi.c')
-rw-r--r--drivers/pci/msi.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/pci/msi.c b/drivers/pci/msi.c
index ccb1974464fb..15af618d36e2 100644
--- a/drivers/pci/msi.c
+++ b/drivers/pci/msi.c
@@ -565,9 +565,8 @@ int pci_enable_msi(struct pci_dev* dev)
565 565
566 /* Check whether driver already requested for MSI-X irqs */ 566 /* Check whether driver already requested for MSI-X irqs */
567 if (dev->msix_enabled) { 567 if (dev->msix_enabled) {
568 printk(KERN_INFO "PCI: %s: Can't enable MSI. " 568 dev_info(&dev->dev, "can't enable MSI "
569 "Device already has MSI-X enabled\n", 569 "(MSI-X already enabled)\n");
570 pci_name(dev));
571 return -EINVAL; 570 return -EINVAL;
572 } 571 }
573 status = msi_capability_init(dev); 572 status = msi_capability_init(dev);
@@ -690,9 +689,8 @@ int pci_enable_msix(struct pci_dev* dev, struct msix_entry *entries, int nvec)
690 689
691 /* Check whether driver already requested for MSI irq */ 690 /* Check whether driver already requested for MSI irq */
692 if (dev->msi_enabled) { 691 if (dev->msi_enabled) {
693 printk(KERN_INFO "PCI: %s: Can't enable MSI-X. " 692 dev_info(&dev->dev, "can't enable MSI-X "
694 "Device already has an MSI irq assigned\n", 693 "(MSI IRQ already assigned)\n");
695 pci_name(dev));
696 return -EINVAL; 694 return -EINVAL;
697 } 695 }
698 status = msix_capability_init(dev, entries, nvec); 696 status = msix_capability_init(dev, entries, nvec);