PCI: replace pr_debug with dev_dbg
Since we have a struct device, we might as well use dev_printk. Note that both pr_debug() and dev_dbg() are completely compiled out unless DEBUG or DYNAMIC_DEBUG is defined. Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
This commit is contained in:
committed by
Jesse Barnes
parent
2a6bed8301
commit
0207c356ef
@@ -1121,7 +1121,7 @@ unsigned int __devinit pci_scan_child_bus(struct pci_bus *bus)
|
|||||||
unsigned int devfn, pass, max = bus->secondary;
|
unsigned int devfn, pass, max = bus->secondary;
|
||||||
struct pci_dev *dev;
|
struct pci_dev *dev;
|
||||||
|
|
||||||
pr_debug("PCI: Scanning bus %04x:%02x\n", pci_domain_nr(bus), bus->number);
|
dev_dbg(&bus->dev, "scanning bus\n");
|
||||||
|
|
||||||
/* Go find them, Rover! */
|
/* Go find them, Rover! */
|
||||||
for (devfn = 0; devfn < 0x100; devfn += 8)
|
for (devfn = 0; devfn < 0x100; devfn += 8)
|
||||||
@@ -1135,8 +1135,7 @@ unsigned int __devinit pci_scan_child_bus(struct pci_bus *bus)
|
|||||||
* all PCI-to-PCI bridges on this bus.
|
* all PCI-to-PCI bridges on this bus.
|
||||||
*/
|
*/
|
||||||
if (!bus->is_added) {
|
if (!bus->is_added) {
|
||||||
pr_debug("PCI: Fixups for bus %04x:%02x\n",
|
dev_dbg(&bus->dev, "fixups for bus\n");
|
||||||
pci_domain_nr(bus), bus->number);
|
|
||||||
pcibios_fixup_bus(bus);
|
pcibios_fixup_bus(bus);
|
||||||
if (pci_is_root_bus(bus))
|
if (pci_is_root_bus(bus))
|
||||||
bus->is_added = 1;
|
bus->is_added = 1;
|
||||||
@@ -1156,8 +1155,7 @@ unsigned int __devinit pci_scan_child_bus(struct pci_bus *bus)
|
|||||||
*
|
*
|
||||||
* Return how far we've got finding sub-buses.
|
* Return how far we've got finding sub-buses.
|
||||||
*/
|
*/
|
||||||
pr_debug("PCI: Bus scan for %04x:%02x returning with max=%02x\n",
|
dev_dbg(&bus->dev, "bus scan returning with max=%02x\n", max);
|
||||||
pci_domain_nr(bus), bus->number, max);
|
|
||||||
return max;
|
return max;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1165,7 +1163,7 @@ struct pci_bus * pci_create_bus(struct device *parent,
|
|||||||
int bus, struct pci_ops *ops, void *sysdata)
|
int bus, struct pci_ops *ops, void *sysdata)
|
||||||
{
|
{
|
||||||
int error;
|
int error;
|
||||||
struct pci_bus *b;
|
struct pci_bus *b, *b2;
|
||||||
struct device *dev;
|
struct device *dev;
|
||||||
|
|
||||||
b = pci_alloc_bus();
|
b = pci_alloc_bus();
|
||||||
@@ -1181,9 +1179,10 @@ struct pci_bus * pci_create_bus(struct device *parent,
|
|||||||
b->sysdata = sysdata;
|
b->sysdata = sysdata;
|
||||||
b->ops = ops;
|
b->ops = ops;
|
||||||
|
|
||||||
if (pci_find_bus(pci_domain_nr(b), bus)) {
|
b2 = pci_find_bus(pci_domain_nr(b), bus);
|
||||||
|
if (b2) {
|
||||||
/* If we already got to this bus through a different bridge, ignore it */
|
/* If we already got to this bus through a different bridge, ignore it */
|
||||||
pr_debug("PCI: Bus %04x:%02x already known\n", pci_domain_nr(b), bus);
|
dev_dbg(&b2->dev, "bus already known\n");
|
||||||
goto err_out;
|
goto err_out;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user