Commit ae85b23c authored by Stafford Horne's avatar Stafford Horne Committed by Bjorn Helgaas
Browse files

PCI: Remove pci_get_legacy_ide_irq() and asm-generic/pci.h



pci_get_legacy_ide_irq() is only used on platforms that support PNP, so
many architectures define it but never use it.  Replace uses of it with
ATA_PRIMARY_IRQ() and ATA_SECONDARY_IRQ(), which provide the same
functionality.

Since pci_get_legacy_ide_irq() is no longer used, remove all the
architecture-specific definitions of it as well as asm-generic/pci.h, which
only provides pci_get_legacy_ide_irq()

[bhelgaas: commit log]
Co-developed-by: default avatarArnd Bergmann <arnd@arndb.de>
Link: https://lore.kernel.org/r/20220722214944.831438-2-shorne@gmail.com


Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
Signed-off-by: default avatarStafford Horne <shorne@gmail.com>
Signed-off-by: default avatarBjorn Helgaas <bhelgaas@google.com>
Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
Acked-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
Acked-by: default avatarPierre Morel <pmorel@linux.ibm.com>
Acked-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent f2906aa8
Loading
Loading
Loading
Loading
+0 −6
Original line number Diff line number Diff line
@@ -56,12 +56,6 @@ struct pci_controller {

/* IOMMU controls.  */

/* TODO: integrate with include/asm-generic/pci.h ? */
static inline int pci_get_legacy_ide_irq(struct pci_dev *dev, int channel)
{
	return channel ? 15 : 14;
}

#define pci_domain_nr(bus) ((struct pci_controller *)(bus)->sysdata)->index

static inline int pci_proc_domain(struct pci_bus *bus)
+0 −5
Original line number Diff line number Diff line
@@ -22,11 +22,6 @@ static inline int pci_proc_domain(struct pci_bus *bus)
#define HAVE_PCI_MMAP
#define ARCH_GENERIC_PCI_MMAP_RESOURCE

static inline int pci_get_legacy_ide_irq(struct pci_dev *dev, int channel)
{
	return channel ? 15 : 14;
}

extern void pcibios_report_status(unsigned int status_mask, int warn);

#endif /* __KERNEL__ */
+0 −6
Original line number Diff line number Diff line
@@ -23,12 +23,6 @@
extern int isa_dma_bridge_buggy;

#ifdef CONFIG_PCI
static inline int pci_get_legacy_ide_irq(struct pci_dev *dev, int channel)
{
	/* no legacy IRQ on arm64 */
	return -ENODEV;
}

static inline int pci_proc_domain(struct pci_bus *bus)
{
	return 1;
+0 −6
Original line number Diff line number Diff line
@@ -18,12 +18,6 @@
extern int isa_dma_bridge_buggy;

#ifdef CONFIG_PCI
static inline int pci_get_legacy_ide_irq(struct pci_dev *dev, int channel)
{
	/* no legacy IRQ on csky */
	return -ENODEV;
}

static inline int pci_proc_domain(struct pci_bus *bus)
{
	/* always show the domain in /proc */
+0 −6
Original line number Diff line number Diff line
@@ -63,10 +63,4 @@ static inline int pci_proc_domain(struct pci_bus *bus)
	return (pci_domain_nr(bus) != 0);
}

#define HAVE_ARCH_PCI_GET_LEGACY_IDE_IRQ
static inline int pci_get_legacy_ide_irq(struct pci_dev *dev, int channel)
{
	return channel ? isa_irq_to_vector(15) : isa_irq_to_vector(14);
}

#endif /* _ASM_IA64_PCI_H */
Loading