Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b28626da authored by Russell King's avatar Russell King
Browse files

ARM: PCI: integrator: use common PCI swizzle



The Integrator swizzle function is almost the same as the standard PCI
swizzle, except for an initial check for pin = 0.  Make the integrator
swizzle function a wrapper around the standard PCI swizzle function so
we preseve this behaviour while using common code.

[fix to use pci_std_swizzle from Linus Walleij]

Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
parent 66e9279a
Loading
Loading
Loading
Loading
+3 −14
Original line number Original line Diff line number Diff line
@@ -70,21 +70,10 @@
 */
 */
static u8 __init integrator_swizzle(struct pci_dev *dev, u8 *pinp)
static u8 __init integrator_swizzle(struct pci_dev *dev, u8 *pinp)
{
{
	int pin = *pinp;
	if (*pinp == 0)
		*pinp = 1;


	if (pin == 0)
	return pci_common_swizzle(dev, pinp);
		pin = 1;

	while (dev->bus->self) {
		pin = pci_swizzle_interrupt_pin(dev, pin);
		/*
		 * move up the chain of bridges, swizzling as we go.
		 */
		dev = dev->bus->self;
	}
	*pinp = pin;

	return PCI_SLOT(dev->devfn);
}
}


static int irq_tab[4] __initdata = {
static int irq_tab[4] __initdata = {