summaryrefslogtreecommitdiff
path: root/target/linux/ixp4xx/patches-4.4/910-ixp4xx-nr_irq_lines.patch
blob: 06e09f469de5cb081a8f068f3381c42aff55efcd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
--- a/arch/arm/mach-ixp4xx/ixdp425-pci.c
+++ b/arch/arm/mach-ixp4xx/ixdp425-pci.c
@@ -53,7 +53,7 @@ static int __init ixdp425_map_irq(const
 	};
 
 	if (slot >= 1 && slot <= MAX_DEV && pin >= 1 && pin <= IRQ_LINES)
-		return pci_irq_table[(slot + pin - 2) % 4];
+		return pci_irq_table[(slot + pin - 2) % IRQ_LINES];
 
 	return -1;
 }
--- a/arch/arm/mach-ixp4xx/miccpt-pci.c
+++ b/arch/arm/mach-ixp4xx/miccpt-pci.c
@@ -54,7 +54,7 @@ static int __init miccpt_map_irq(const s
 	};
 
 	if (slot >= 1 && slot <= MAX_DEV && pin >= 1 && pin <= IRQ_LINES)
-		return pci_irq_table[(slot + pin - 2) % 4];
+		return pci_irq_table[(slot + pin - 2) % IRQ_LINES];
 
 	return -1;
 }