Commit 63eceba1 authored by David S. Miller's avatar David S. Miller

[SPARC64]: Use domain in naming PCI buses.

parent 9073380e
...@@ -798,6 +798,12 @@ int pci_domain_nr(struct pci_bus *pbus) ...@@ -798,6 +798,12 @@ int pci_domain_nr(struct pci_bus *pbus)
return ret; return ret;
} }
int pci_name_bus(char *name, struct pci_bus *bus)
{
sprintf(name, "%04x:%02x", pci_domain_nr(bus), bus->number);
return 0;
}
int pcibios_prep_mwi(struct pci_dev *dev) int pcibios_prep_mwi(struct pci_dev *dev)
{ {
/* We set correct PCI_CACHE_LINE_SIZE register values for every /* We set correct PCI_CACHE_LINE_SIZE register values for every
......
...@@ -190,13 +190,7 @@ pci_dac_dma_sync_single(struct pci_dev *pdev, dma64_addr_t dma_addr, size_t len, ...@@ -190,13 +190,7 @@ pci_dac_dma_sync_single(struct pci_dev *pdev, dma64_addr_t dma_addr, size_t len,
/* Return the index of the PCI controller for device PDEV. */ /* Return the index of the PCI controller for device PDEV. */
extern int pci_domain_nr(struct pci_bus *bus); extern int pci_domain_nr(struct pci_bus *bus);
extern int pci_name_bus(char *name, struct pci_bus *bus);
/* Set the name of the bus as it appears in /proc/bus/pci */
static inline int pci_name_bus(char *name, struct pci_bus *bus)
{
sprintf(name, "%02x", bus->number);
return 0;
}
/* Platform support for /proc/bus/pci/X/Y mmap()s. */ /* Platform support for /proc/bus/pci/X/Y mmap()s. */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment