diff options
author | Russell King <rmk@dyn-67.arm.linux.org.uk> | 2008-01-14 17:30:10 -0500 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2008-01-28 08:13:19 -0500 |
commit | e7b3dc7ef1e27fd5713a0df71f82c0a27de1c2eb (patch) | |
tree | f7a6b3b79c7340d4aba0e66b16c8bfdb19e6bc87 /arch/arm/mach-pxa | |
parent | 1709e2af784ea658cec4e91fc884508d1214d6f5 (diff) |
[NET] smc91x: Make smc91x use IRQ resource trigger flags
smc91x is shared between many different platforms. Each platform needs
to specify the interrupt type, and in some cases the irq type depends
on more than just the build configuration - it depends on runtime
checks.
Rather than throwing this code into the SMC_IRQ_FLAGS definition, provide
a way for these flags to be passed via the IRQ resource itself.
Note that IRQF_TRIGGER_* constants are intentionally defined to correspond
with the IORESOURCE_IRQ_* interrupt type flags, in much the same way that
the low bits of PCI iomem resources correspond with the BAR flag bits.
Also provide a way to configure smc91x to read the IRQ flags from the
resource. Once all platforms have been converted over (signified
by all definitions of SMC_IRQ_FLAGS being -1) SMC_IRQ_FLAGS should
be removed.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Acked-by: Nicolas Pitre <nico@cam.org>
Acked-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'arch/arm/mach-pxa')
-rw-r--r-- | arch/arm/mach-pxa/idp.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-pxa/littleton.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-pxa/lubbock.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-pxa/mainstone.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-pxa/zylonite.c | 2 |
5 files changed, 5 insertions, 5 deletions
diff --git a/arch/arm/mach-pxa/idp.c b/arch/arm/mach-pxa/idp.c index 465108da285..0a9434432c5 100644 --- a/arch/arm/mach-pxa/idp.c +++ b/arch/arm/mach-pxa/idp.c | |||
@@ -54,7 +54,7 @@ static struct resource smc91x_resources[] = { | |||
54 | [1] = { | 54 | [1] = { |
55 | .start = IRQ_GPIO(4), | 55 | .start = IRQ_GPIO(4), |
56 | .end = IRQ_GPIO(4), | 56 | .end = IRQ_GPIO(4), |
57 | .flags = IORESOURCE_IRQ, | 57 | .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_HIGHEDGE, |
58 | } | 58 | } |
59 | }; | 59 | }; |
60 | 60 | ||
diff --git a/arch/arm/mach-pxa/littleton.c b/arch/arm/mach-pxa/littleton.c index e408a3a89bb..0a4b54c2131 100644 --- a/arch/arm/mach-pxa/littleton.c +++ b/arch/arm/mach-pxa/littleton.c | |||
@@ -87,7 +87,7 @@ static struct resource smc91x_resources[] = { | |||
87 | [1] = { | 87 | [1] = { |
88 | .start = IRQ_GPIO(mfp_to_gpio(MFP_PIN_GPIO90)), | 88 | .start = IRQ_GPIO(mfp_to_gpio(MFP_PIN_GPIO90)), |
89 | .end = IRQ_GPIO(mfp_to_gpio(MFP_PIN_GPIO90)), | 89 | .end = IRQ_GPIO(mfp_to_gpio(MFP_PIN_GPIO90)), |
90 | .flags = IORESOURCE_IRQ, | 90 | .flags = IORESOURCE_IRQ | IRQF_TRIGGER_FALLING, |
91 | } | 91 | } |
92 | }; | 92 | }; |
93 | 93 | ||
diff --git a/arch/arm/mach-pxa/lubbock.c b/arch/arm/mach-pxa/lubbock.c index a75594bf68b..e7ae4bb3e36 100644 --- a/arch/arm/mach-pxa/lubbock.c +++ b/arch/arm/mach-pxa/lubbock.c | |||
@@ -196,7 +196,7 @@ static struct resource smc91x_resources[] = { | |||
196 | [1] = { | 196 | [1] = { |
197 | .start = LUBBOCK_ETH_IRQ, | 197 | .start = LUBBOCK_ETH_IRQ, |
198 | .end = LUBBOCK_ETH_IRQ, | 198 | .end = LUBBOCK_ETH_IRQ, |
199 | .flags = IORESOURCE_IRQ, | 199 | .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_HIGHEDGE, |
200 | }, | 200 | }, |
201 | [2] = { | 201 | [2] = { |
202 | .name = "smc91x-attrib", | 202 | .name = "smc91x-attrib", |
diff --git a/arch/arm/mach-pxa/mainstone.c b/arch/arm/mach-pxa/mainstone.c index 06e13608a2c..ac78dbd6a63 100644 --- a/arch/arm/mach-pxa/mainstone.c +++ b/arch/arm/mach-pxa/mainstone.c | |||
@@ -156,7 +156,7 @@ static struct resource smc91x_resources[] = { | |||
156 | [1] = { | 156 | [1] = { |
157 | .start = MAINSTONE_IRQ(3), | 157 | .start = MAINSTONE_IRQ(3), |
158 | .end = MAINSTONE_IRQ(3), | 158 | .end = MAINSTONE_IRQ(3), |
159 | .flags = IORESOURCE_IRQ, | 159 | .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_HIGHEDGE, |
160 | } | 160 | } |
161 | }; | 161 | }; |
162 | 162 | ||
diff --git a/arch/arm/mach-pxa/zylonite.c b/arch/arm/mach-pxa/zylonite.c index b49c69d024c..7731d50dd86 100644 --- a/arch/arm/mach-pxa/zylonite.c +++ b/arch/arm/mach-pxa/zylonite.c | |||
@@ -47,7 +47,7 @@ static struct resource smc91x_resources[] = { | |||
47 | [1] = { | 47 | [1] = { |
48 | .start = -1, /* for run-time assignment */ | 48 | .start = -1, /* for run-time assignment */ |
49 | .end = -1, | 49 | .end = -1, |
50 | .flags = IORESOURCE_IRQ, | 50 | .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_HIGHEDGE, |
51 | } | 51 | } |
52 | }; | 52 | }; |
53 | 53 | ||