powerpc/irq: Move #ifdef'ed body of do_IRQ() into a separate function