patch-2.3.11 linux/arch/i386/kernel/irq.c
Next file: linux/arch/i386/kernel/ldt.c
Previous file: linux/arch/i386/kernel/ioport.c
Back to the patch index
Back to the overall index
- Lines: 45
- Date:
Thu Jul 15 15:50:47 1999
- Orig file:
v2.3.10/linux/arch/i386/kernel/irq.c
- Orig date:
Mon May 10 10:32:45 1999
diff -u --recursive --new-file v2.3.10/linux/arch/i386/kernel/irq.c linux/arch/i386/kernel/irq.c
@@ -27,7 +27,6 @@
#include <linux/malloc.h>
#include <linux/random.h>
#include <linux/smp.h>
-#include <linux/tasks.h>
#include <linux/smp_lock.h>
#include <linux/init.h>
@@ -931,17 +930,21 @@
if (action->dev_id != dev_id)
continue;
- /* Found it - now free it */
+ /* Found it - now remove it from the list of entries */
*p = action->next;
- kfree(action);
if (!irq_desc[irq].action) {
irq_desc[irq].status |= IRQ_DISABLED;
irq_desc[irq].handler->shutdown(irq);
}
- goto out;
+ spin_unlock_irqrestore(&irq_controller_lock,flags);
+
+ /* Wait to make sure it's not being used on another CPU */
+ while (irq_desc[irq].status & IRQ_INPROGRESS)
+ barrier();
+ kfree(action);
+ return;
}
printk("Trying to free free IRQ%d\n",irq);
-out:
spin_unlock_irqrestore(&irq_controller_lock,flags);
}
@@ -1099,9 +1102,7 @@
/* IPI vector for APIC spurious interrupts */
set_intr_gate(SPURIOUS_APIC_VECTOR, spurious_interrupt);
-#endif
- request_region(0x20,0x20,"pic1");
- request_region(0xa0,0x20,"pic2");
+#endif
/*
* Set the clock to 100 Hz, we already have a valid
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)