From: Akinobu Mita Date: Mon, 15 Mar 2010 04:35:01 +0000 (-0400) Subject: hpet: use for_each_set_bit() X-Git-Tag: MMI-PSA29.97-13-9~24362 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e5d6151115aee73825c1752aff7cd09adfece839;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git hpet: use for_each_set_bit() Replace open-coded loop with for_each_set_bit(). Signed-off-by: Akinobu Mita Cc: Clemens Ladisch Cc: Bob Picco Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/drivers/char/hpet.c b/drivers/char/hpet.c index e481c5938bad..9c5eea3ea4de 100644 --- a/drivers/char/hpet.c +++ b/drivers/char/hpet.c @@ -215,9 +215,7 @@ static void hpet_timer_set_irq(struct hpet_dev *devp) else v &= ~0xffff; - for (irq = find_first_bit(&v, HPET_MAX_IRQ); irq < HPET_MAX_IRQ; - irq = find_next_bit(&v, HPET_MAX_IRQ, 1 + irq)) { - + for_each_set_bit(irq, &v, HPET_MAX_IRQ) { if (irq >= nr_irqs) { irq = HPET_MAX_IRQ; break;