summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Schwinge <tschwinge@gnu.org>2006-01-26 14:34:45 +0000
committerThomas Schwinge <tschwinge@gnu.org>2009-06-18 00:26:30 +0200
commitacb792b101fd685262c93b75ebe4c033f2d2c079 (patch)
treeab0793345dafd658eda7c23d1f15d282588f8132
parentb946deee920ef00d65d675ad5d0b6e44884e5c62 (diff)
2006-01-26 Samuel Thibault <samuel.thibault@ens-lyon.org>
* linux/dev/arch/i386/kernel/irq.c (linux_intr): Disable interrupts if the driver requested it through request_irq().
-rw-r--r--ChangeLog3
-rw-r--r--linux/dev/arch/i386/kernel/irq.c7
2 files changed, 10 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index f3e845a..77cf59a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2006-01-26 Samuel Thibault <samuel.thibault@ens-lyon.org>
+ * linux/dev/arch/i386/kernel/irq.c (linux_intr): Disable interrupts
+ if the driver requested it through request_irq().
+
* linux/dev/drivers/block/ide.c (read_intr): Set the IRQ handler before
issuing a request.
(write_intr): Likewise.
diff --git a/linux/dev/arch/i386/kernel/irq.c b/linux/dev/arch/i386/kernel/irq.c
index 1543234..e9dfe6a 100644
--- a/linux/dev/arch/i386/kernel/irq.c
+++ b/linux/dev/arch/i386/kernel/irq.c
@@ -103,16 +103,23 @@ linux_intr (int irq)
{
struct pt_regs regs;
struct linux_action *action = *(irq_action + irq);
+ unsigned long flags;
kstat.interrupts[irq]++;
intr_count++;
+ save_flags (flags);
+ if (action && (action->flags & SA_INTERRUPT))
+ cli ();
+
while (action)
{
action->handler (irq, action->dev_id, &regs);
action = action->next;
}
+ restore_flags (flags);
+
intr_count--;
/* Not used. by OKUJI Yoshinori. */