diff options
author | Wei Yongjun <yongjun_wei@trendmicro.com.cn> | 2012-10-26 10:50:54 -0400 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2012-10-28 15:34:09 -0400 |
commit | 05daa16a86b1f822eeb4324f8874d4d9b915a717 (patch) | |
tree | 540e96475a45f5c6af31c507e20dccb9ff00f957 /drivers/pinctrl/pinctrl-at91.c | |
parent | 11aabdcd747d29dd587ff258db0219d1a4e03dfb (diff) |
pinctrl/at91: using for_each_set_bit to simplify the code
Using for_each_set_bit() to simplify the code.
dpatch engine is used to auto generate this patch.
(https://github.com/weiyj/dpatch)
Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl/pinctrl-at91.c')
-rw-r--r-- | drivers/pinctrl/pinctrl-at91.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/pinctrl/pinctrl-at91.c b/drivers/pinctrl/pinctrl-at91.c index 62f2fe47b46b..ddfb5dbd88db 100644 --- a/drivers/pinctrl/pinctrl-at91.c +++ b/drivers/pinctrl/pinctrl-at91.c | |||
@@ -1219,10 +1219,8 @@ static void gpio_irq_handler(unsigned irq, struct irq_desc *desc) | |||
1219 | continue; | 1219 | continue; |
1220 | } | 1220 | } |
1221 | 1221 | ||
1222 | n = find_first_bit(&isr, BITS_PER_LONG); | 1222 | for_each_set_bit(n, &isr, BITS_PER_LONG) { |
1223 | while (n < BITS_PER_LONG) { | ||
1224 | generic_handle_irq(irq_find_mapping(at91_gpio->domain, n)); | 1223 | generic_handle_irq(irq_find_mapping(at91_gpio->domain, n)); |
1225 | n = find_next_bit(&isr, BITS_PER_LONG, n + 1); | ||
1226 | } | 1224 | } |
1227 | } | 1225 | } |
1228 | chained_irq_exit(chip, desc); | 1226 | chained_irq_exit(chip, desc); |