Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 297594
b: refs/heads/master
c: 9141a00
h: refs/heads/master
v: v3
  • Loading branch information
Will Deacon authored and Russell King committed Mar 24, 2012
1 parent 6d80f0e commit a341aa1
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ba81f502e73cee92964af6c39eb8c8d7e44e38c1
refs/heads/master: 9141a003a491c7230d17b9c29677ce2be437b95c
25 changes: 25 additions & 0 deletions trunk/arch/arm/kernel/machine_kexec.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
#include <linux/delay.h>
#include <linux/reboot.h>
#include <linux/io.h>
#include <linux/irq.h>
#include <asm/pgtable.h>
#include <asm/pgalloc.h>
#include <asm/mmu_context.h>
Expand Down Expand Up @@ -53,6 +54,29 @@ void machine_crash_nonpanic_core(void *unused)
cpu_relax();
}

static void machine_kexec_mask_interrupts(void)
{
unsigned int i;
struct irq_desc *desc;

for_each_irq_desc(i, desc) {
struct irq_chip *chip;

chip = irq_desc_get_chip(desc);
if (!chip)
continue;

if (chip->irq_eoi && irqd_irq_inprogress(&desc->irq_data))
chip->irq_eoi(&desc->irq_data);

if (chip->irq_mask)
chip->irq_mask(&desc->irq_data);

if (chip->irq_disable && !irqd_irq_disabled(&desc->irq_data))
chip->irq_disable(&desc->irq_data);
}
}

void machine_crash_shutdown(struct pt_regs *regs)
{
unsigned long msecs;
Expand All @@ -70,6 +94,7 @@ void machine_crash_shutdown(struct pt_regs *regs)
printk(KERN_WARNING "Non-crashing CPUs did not react to IPI\n");

crash_save_cpu(regs, smp_processor_id());
machine_kexec_mask_interrupts();

printk(KERN_INFO "Loading crashdump kernel...\n");
}
Expand Down

0 comments on commit a341aa1

Please sign in to comment.