summaryrefslogtreecommitdiffstats
path: root/irq-chip-apply-mask-if-IRQ_ONESHOT-is-set.patch
blob: 506ca3547c4406a9f85e8f27f8b66f315009e8c8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
From ba38904c6c2df2ff77ad4e466fc55a92d87ed555 Mon Sep 17 00:00:00 2001
From: Paul Gortmaker <paul.gortmaker@windriver.com>
Date: Sun, 23 Jan 2011 22:33:07 -0500
Subject: [PATCH] irq chip: apply mask if IRQ_ONESHOT is set

This is an extraction from a merge commit in the RT tip tree.

See it in a git tip repo with:

   git diff d94ddace23997c2899e8137f088488773b35eadb^2 \
	d94ddace23997c2899e8137f088488773b35eadb \
	kernel/irq/chip.c

You can find the origin of this change in the tip merge commit:

  Author: Thomas Gleixner <tglx@linutronix.de>
  Date:   Mon Aug 17 20:14:14 2009 +0200

      Merge branch 'rt/base' into rt/head

      Conflicts:
          kernel/irq/chip.c
          kernel/irq/internals.h
          kernel/irq/manage.c

      Convert forced irq threading to the new ONESHOT infrastructure

Normally there are not significant changes/additions in a merge commit that
are not from any other "normal" commit.  But in this case there are, so
break them out into separate explicit commits.
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
---
 kernel/irq/chip.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/kernel/irq/chip.c b/kernel/irq/chip.c
index f308d6c..2c2214d 100644
--- a/kernel/irq/chip.c
+++ b/kernel/irq/chip.c
@@ -544,6 +544,9 @@ handle_fasteoi_irq(unsigned int irq, struct irq_desc *desc)
 		goto out;
 	}
 
+	if ((desc->status & IRQ_ONESHOT) && desc->chip->mask)
+		desc->chip->mask(irq);
+
 	desc->status |= IRQ_INPROGRESS;
 	desc->status &= ~IRQ_PENDING;
 	raw_spin_unlock(&desc->lock);
-- 
1.7.0.4