From: Christian Ehrhardt <ehrhardt@xxxxxxxxxxxxxxxxxx> Since we use a unsigned long here anyway we can use the optimized __ffs. Signed-off-by: Christian Ehrhardt <ehrhardt@xxxxxxxxxxxxxxxxxx> --- [diffstat] booke_guest.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) [diff] diff --git a/arch/powerpc/kvm/booke_guest.c b/arch/powerpc/kvm/booke_guest.c --- a/arch/powerpc/kvm/booke_guest.c +++ b/arch/powerpc/kvm/booke_guest.c @@ -180,7 +180,7 @@ unsigned int prio; u32 mask; - prio = find_first_bit(pending, BITS_PER_BYTE * sizeof(*pending)); + prio = __ffs(*pending); while (prio <= BOOKE_MAX_INTERRUPT) { if (kvmppc_can_deliver_interrupt_by_prio(vcpu, prio, &mask)) { kvmppc_clear_exception_by_prio(pending, prio); -- To unsubscribe from this list: send the line "unsubscribe kvm-ppc" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html