Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 362842
b: refs/heads/master
c: d303e9e
h: refs/heads/master
v: v3
  • Loading branch information
Tony Luck committed Apr 2, 2013
1 parent d053886 commit 3ea0753
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 14 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 96edc754aa714e51d2044af91b96cc7420c5cb01
refs/heads/master: d303e9e98fce56cdb3c6f2ac92f626fc2bd51c77
1 change: 1 addition & 0 deletions trunk/arch/ia64/include/asm/mca.h
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ extern unsigned long __per_cpu_mca[NR_CPUS];
extern int cpe_vector;
extern int ia64_cpe_irq;
extern void ia64_mca_init(void);
extern void ia64_mca_irq_init(void);
extern void ia64_mca_cpu_init(void *);
extern void ia64_os_mca_dispatch(void);
extern void ia64_os_mca_dispatch_end(void);
Expand Down
8 changes: 8 additions & 0 deletions trunk/arch/ia64/kernel/irq.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
#include <linux/interrupt.h>
#include <linux/kernel_stat.h>

#include <asm/mca.h>

/*
* 'what should we do if we get a hw irq event on an illegal vector'.
* each architecture has to answer this themselves.
Expand Down Expand Up @@ -83,6 +85,12 @@ bool is_affinity_mask_valid(const struct cpumask *cpumask)

#endif /* CONFIG_SMP */

int __init arch_early_irq_init(void)
{
ia64_mca_irq_init();
return 0;
}

#ifdef CONFIG_HOTPLUG_CPU
unsigned int vectors_in_migration[NR_IRQS];

Expand Down
37 changes: 24 additions & 13 deletions trunk/arch/ia64/kernel/mca.c
Original file line number Diff line number Diff line change
Expand Up @@ -2074,22 +2074,16 @@ ia64_mca_init(void)
printk(KERN_INFO "MCA related initialization done\n");
}


/*
* ia64_mca_late_init
*
* Opportunity to setup things that require initialization later
* than ia64_mca_init. Setup a timer to poll for CPEs if the
* platform doesn't support an interrupt driven mechanism.
*
* Inputs : None
* Outputs : Status
* These pieces cannot be done in ia64_mca_init() because it is called before
* early_irq_init() which would wipe out our percpu irq registrations. But we
* cannot leave them until ia64_mca_late_init() because by then all the other
* processors have been brought online and have set their own CMC vectors to
* point at a non-existant action. Called from arch_early_irq_init().
*/
static int __init
ia64_mca_late_init(void)
void __init ia64_mca_irq_init(void)
{
if (!mca_init)
return 0;

/*
* Configure the CMCI/P vector and handler. Interrupts for CMC are
* per-processor, so AP CMC interrupts are setup in smp_callin() (smpboot.c).
Expand All @@ -2108,6 +2102,23 @@ ia64_mca_late_init(void)
/* Setup the CPEI/P handler */
register_percpu_irq(IA64_CPEP_VECTOR, &mca_cpep_irqaction);
#endif
}

/*
* ia64_mca_late_init
*
* Opportunity to setup things that require initialization later
* than ia64_mca_init. Setup a timer to poll for CPEs if the
* platform doesn't support an interrupt driven mechanism.
*
* Inputs : None
* Outputs : Status
*/
static int __init
ia64_mca_late_init(void)
{
if (!mca_init)
return 0;

register_hotcpu_notifier(&mca_cpu_notifier);

Expand Down

0 comments on commit 3ea0753

Please sign in to comment.