Skip to contentSkip to conversation

arch: alpha: kernel: remove deprecated call to pci_get_slot

PATCH In review Pierre Chevalier 2 participants 2 messages Feb 5, 2015 – May 21, 2015 Alpha port

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 arch: alpha: kernel: remove deprecated call to pci_get_slot

According to Documentation/PCI/pci.txt, pci_get_slot has been superseded by pci_get_domain_bus_and_slot.

---
 arch/alpha/kernel/sys_miata.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
arch/alpha/kernel/sys_miata.c +2 -1
index d5b9776..7b98b40 100644
@@ -182,7 +182,8 @@ miata_map_irq(const struct pci_dev *dev, u8 slot, u8 pin)
 
 	if((slot == 7) && (PCI_FUNC(dev->devfn) == 3)) {
 		u8 irq=0;
-		struct pci_dev *pdev = pci_get_slot(dev->bus, dev->devfn & ~7);
+		struct pci_dev *pdev =
+			pci_get_domain_bus_and_slot(dev->bus, dev->devfn & ~7);
 		if(pdev == NULL || pci_read_config_byte(pdev, 0x40,&irq) != PCIBIOS_SUCCESSFUL) {
 			pci_dev_put(pdev);
 			return -1;
Signature · 1 line
2.2.2
maintainer
#1 lore raw
Quoted 13 lines · Pierre Chevalier

According to Documentation/PCI/pci.txt, pci_get_slot has been superseded by pci_get_domain_bus_and_slot.

---
 arch/alpha/kernel/sys_miata.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
arch/alpha/kernel/sys_miata.c +0 -0
index d5b9776..7b98b40 100644

arch/alpha/kernel/sys_miata.c miata_map_irq(const struct pci_dev *dev, u8 slot, u8 pin) · line 186

Quoted 6 lines
arch/alpha/kernel/sys_miata.c +2 -1
@@ -182,7 +182,8 @@ miata_map_irq(const struct pci_dev *dev, u8 slot, u8 pin)
 
        if((slot == 7) && (PCI_FUNC(dev->devfn) == 3)) {
                u8 irq=0;
-               struct pci_dev *pdev = pci_get_slot(dev->bus, dev->devfn & ~7);
+               struct pci_dev *pdev =
+                       pci_get_domain_bus_and_slot(dev->bus, dev->devfn & ~7);

Given that pci_get_domain_bus_and_slot takes three arguments, I don't think this compiles.