[PATCH] Better timer and RTC handling for 8641HPCN.

Zhang Wei-r63237 Wei.Zhang at freescale.com
Thu Mar 8 13:09:05 EST 2007


Hi, Kumar,

> >  	/* Alloc mpic structure and per isu has 16 INT entries. */
> >  	mpic1 = mpic_alloc(np, res.start,
> >  			MPIC_PRIMARY | MPIC_WANTS_RESET | 
> MPIC_BIG_ENDIAN,
> > -			16, NR_IRQS - 4,
> > +			16, NR_IRQS - 10,
> >  			" MPIC     ");
> 
> Why is the number of interrupts reduced by 10?

There's IRQs reserved for mpic using in mpic.c around line 962:

	mpic->timer_vecs[0] = intvec_top - 8;
	mpic->timer_vecs[1] = intvec_top - 7;
	mpic->timer_vecs[2] = intvec_top - 6;
	mpic->timer_vecs[3] = intvec_top - 5;
	mpic->ipi_vecs[0]   = intvec_top - 4;
	mpic->ipi_vecs[1]   = intvec_top - 3;
	mpic->ipi_vecs[2]   = intvec_top - 2;
	mpic->ipi_vecs[3]   = intvec_top - 1;
	mpic->spurious_vec  = intvec_top;

So I reduces it by 10 for IRQs reserved (leave 1 more space for
further).

Thanks!

Best Regards,
Zhang Wei



More information about the Linuxppc-dev mailing list