genirq: Mirror irq trigger type bits in irq_data.state

That's the data structure chip functions get provided. Also allow them
to signal the core code that they updated the flags in irq_data.state
by returning IRQ_SET_MASK_OK_NOCOPY. The default is unchanged.

The type bits should be accessed via:

val = irqd_get_trigger_type(irqdata);
and
irqd_set_trigger_type(irqdata, val);

Coders who access them directly will be tracked down and slapped with
stinking trouts.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
This commit is contained in:
Thomas Gleixner
2011-02-08 17:28:12 +01:00
parent 2bdd10558c
commit 876dbd4cc1
5 changed files with 87 additions and 20 deletions

View File

@@ -60,7 +60,7 @@ void check_irq_resend(struct irq_desc *desc, unsigned int irq)
* interrupts are resent by hardware when they are still
* active.
*/
if (desc->status & IRQ_LEVEL)
if (irq_settings_is_level(desc))
return;
if (desc->istate & IRQS_REPLAY)
return;