diff options
author | Lennert Buytenhek <buytenh@wantstofly.org> | 2010-11-29 05:16:23 -0500 |
---|---|---|
committer | Lennert Buytenhek <buytenh@wantstofly.org> | 2011-01-13 11:19:09 -0500 |
commit | 4d93579f63ca4998284934c43ac03fcee4216f91 (patch) | |
tree | 6458f1d81df9fe99b445873b0842109bfeba7156 /arch/arm/plat-mxc/gpio.c | |
parent | b9858efad32ffa8b3e9c2bd1286121824c3cebae (diff) |
ARM: plat-mxc: irq_data conversion.
Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
Diffstat (limited to 'arch/arm/plat-mxc/gpio.c')
-rw-r--r-- | arch/arm/plat-mxc/gpio.c | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/arch/arm/plat-mxc/gpio.c b/arch/arm/plat-mxc/gpio.c index bc2c7bc6f10a..d17b3c996b84 100644 --- a/arch/arm/plat-mxc/gpio.c +++ b/arch/arm/plat-mxc/gpio.c | |||
@@ -63,29 +63,29 @@ static void _set_gpio_irqenable(struct mxc_gpio_port *port, u32 index, | |||
63 | __raw_writel(l, port->base + GPIO_IMR); | 63 | __raw_writel(l, port->base + GPIO_IMR); |
64 | } | 64 | } |
65 | 65 | ||
66 | static void gpio_ack_irq(u32 irq) | 66 | static void gpio_ack_irq(struct irq_data *d) |
67 | { | 67 | { |
68 | u32 gpio = irq_to_gpio(irq); | 68 | u32 gpio = irq_to_gpio(d->irq); |
69 | _clear_gpio_irqstatus(&mxc_gpio_ports[gpio / 32], gpio & 0x1f); | 69 | _clear_gpio_irqstatus(&mxc_gpio_ports[gpio / 32], gpio & 0x1f); |
70 | } | 70 | } |
71 | 71 | ||
72 | static void gpio_mask_irq(u32 irq) | 72 | static void gpio_mask_irq(struct irq_data *d) |
73 | { | 73 | { |
74 | u32 gpio = irq_to_gpio(irq); | 74 | u32 gpio = irq_to_gpio(d->irq); |
75 | _set_gpio_irqenable(&mxc_gpio_ports[gpio / 32], gpio & 0x1f, 0); | 75 | _set_gpio_irqenable(&mxc_gpio_ports[gpio / 32], gpio & 0x1f, 0); |
76 | } | 76 | } |
77 | 77 | ||
78 | static void gpio_unmask_irq(u32 irq) | 78 | static void gpio_unmask_irq(struct irq_data *d) |
79 | { | 79 | { |
80 | u32 gpio = irq_to_gpio(irq); | 80 | u32 gpio = irq_to_gpio(d->irq); |
81 | _set_gpio_irqenable(&mxc_gpio_ports[gpio / 32], gpio & 0x1f, 1); | 81 | _set_gpio_irqenable(&mxc_gpio_ports[gpio / 32], gpio & 0x1f, 1); |
82 | } | 82 | } |
83 | 83 | ||
84 | static int mxc_gpio_get(struct gpio_chip *chip, unsigned offset); | 84 | static int mxc_gpio_get(struct gpio_chip *chip, unsigned offset); |
85 | 85 | ||
86 | static int gpio_set_irq_type(u32 irq, u32 type) | 86 | static int gpio_set_irq_type(struct irq_data *d, u32 type) |
87 | { | 87 | { |
88 | u32 gpio = irq_to_gpio(irq); | 88 | u32 gpio = irq_to_gpio(d->irq); |
89 | struct mxc_gpio_port *port = &mxc_gpio_ports[gpio / 32]; | 89 | struct mxc_gpio_port *port = &mxc_gpio_ports[gpio / 32]; |
90 | u32 bit, val; | 90 | u32 bit, val; |
91 | int edge; | 91 | int edge; |
@@ -211,9 +211,9 @@ static void mx2_gpio_irq_handler(u32 irq, struct irq_desc *desc) | |||
211 | * @param enable enable as wake-up if equal to non-zero | 211 | * @param enable enable as wake-up if equal to non-zero |
212 | * @return This function returns 0 on success. | 212 | * @return This function returns 0 on success. |
213 | */ | 213 | */ |
214 | static int gpio_set_wake_irq(u32 irq, u32 enable) | 214 | static int gpio_set_wake_irq(struct irq_data *d, u32 enable) |
215 | { | 215 | { |
216 | u32 gpio = irq_to_gpio(irq); | 216 | u32 gpio = irq_to_gpio(d->irq); |
217 | u32 gpio_idx = gpio & 0x1F; | 217 | u32 gpio_idx = gpio & 0x1F; |
218 | struct mxc_gpio_port *port = &mxc_gpio_ports[gpio / 32]; | 218 | struct mxc_gpio_port *port = &mxc_gpio_ports[gpio / 32]; |
219 | 219 | ||
@@ -233,11 +233,11 @@ static int gpio_set_wake_irq(u32 irq, u32 enable) | |||
233 | } | 233 | } |
234 | 234 | ||
235 | static struct irq_chip gpio_irq_chip = { | 235 | static struct irq_chip gpio_irq_chip = { |
236 | .ack = gpio_ack_irq, | 236 | .irq_ack = gpio_ack_irq, |
237 | .mask = gpio_mask_irq, | 237 | .irq_mask = gpio_mask_irq, |
238 | .unmask = gpio_unmask_irq, | 238 | .irq_unmask = gpio_unmask_irq, |
239 | .set_type = gpio_set_irq_type, | 239 | .irq_set_type = gpio_set_irq_type, |
240 | .set_wake = gpio_set_wake_irq, | 240 | .irq_set_wake = gpio_set_wake_irq, |
241 | }; | 241 | }; |
242 | 242 | ||
243 | static void _set_gpio_direction(struct gpio_chip *chip, unsigned offset, | 243 | static void _set_gpio_direction(struct gpio_chip *chip, unsigned offset, |