[PATCH 1/3] Adapt ipic driver to new host_ops interface, addset_irq_type to set IRQ sense

Li Yang-r58472 LeoLi at freescale.com
Thu Aug 24 15:44:52 EST 2006


> > +static int ipic_host_map(struct irq_host *h, unsigned int virq,
> > +			 irq_hw_number_t hw)
> > +{
> > +	struct ipic *ipic = h->host_data;
> > +	struct irq_chip *chip;
> > +
> > +	/* Default chip */
> > +	chip = &ipic->hc_irq;
> > +
> > +	set_irq_chip_data(virq, ipic);
> > +	set_irq_chip(virq, chip);
> > +
> > +	return 0;
> >  }
> 
> Shouldn't you call set_irq_type() (or at least set a handler) here to
> setup a default type ? The common code will only call set_irq_type()
if
> an explicit non-default and different than the current setting handler
> is set.

But for IRQ with a specified type, set_irq_type() will be called two
times continuously.  Why not call the set_irq_type() in any case in
irq_create_of_mapping()?




More information about the Linuxppc-dev mailing list