Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 225857
b: refs/heads/master
c: 5210864
h: refs/heads/master
i:
  225855: 79e4c24
v: v3
  • Loading branch information
eric miao authored and Russell King committed Dec 24, 2010
1 parent 9eb8e5e commit d38d2ab
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 3 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: 4a50bfe365a977f634311504484342fbfffe855c
refs/heads/master: 521086412ee423fbdfc7da81f257239c43f707b4
5 changes: 5 additions & 0 deletions trunk/arch/arm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -1022,6 +1022,11 @@ config CPU_HAS_PMU
default y
bool

config MULTI_IRQ_HANDLER
bool
help
Allow each machine to specify it's own IRQ handler at run time.

if !MMU
source "arch/arm/Kconfig-nommu"
endif
Expand Down
3 changes: 3 additions & 0 deletions trunk/arch/arm/include/asm/mach/arch.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ struct machine_desc {
void (*init_irq)(void);
struct sys_timer *timer; /* system tick timer */
void (*init_machine)(void);
#ifdef CONFIG_MULTI_IRQ_HANDLER
void (*handle_irq)(struct pt_regs *);
#endif
};

/*
Expand Down
4 changes: 4 additions & 0 deletions trunk/arch/arm/include/asm/mach/irq.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ extern void (*init_arch_irq)(void);
extern void init_FIQ(void);
extern int show_fiq_list(struct seq_file *, void *);

#ifdef CONFIG_MULTI_IRQ_HANDLER
extern void (*handle_arch_irq)(struct pt_regs *);
#endif

/*
* This is for easy migration, but should be changed in the source
*/
Expand Down
17 changes: 15 additions & 2 deletions trunk/arch/arm/kernel/entry-armv.S
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,14 @@
* Interrupt handling. Preserves r7, r8, r9
*/
.macro irq_handler
#ifdef CONFIG_MULTI_IRQ_HANDLER
ldr r5, =handle_arch_irq
mov r0, sp
ldr r5, [r5]
adr lr, BSYM(9997f)
teq r5, #0
movne pc, r5
#endif
get_irqnr_preamble r5, lr
1: get_irqnr_and_base r0, r6, r5, lr
movne r1, sp
Expand Down Expand Up @@ -58,9 +66,8 @@
adrne lr, BSYM(1b)
bne do_local_timer
#endif
9997:
#endif

9997:
.endm

#ifdef CONFIG_KPROBES
Expand Down Expand Up @@ -1245,3 +1252,9 @@ cr_alignment:
.space 4
cr_no_alignment:
.space 4

#ifdef CONFIG_MULTI_IRQ_HANDLER
.globl handle_arch_irq
handle_arch_irq:
.space 4
#endif
3 changes: 3 additions & 0 deletions trunk/arch/arm/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -875,6 +875,9 @@ void __init setup_arch(char **cmdline_p)
init_arch_irq = mdesc->init_irq;
system_timer = mdesc->timer;
init_machine = mdesc->init_machine;
#ifdef CONFIG_MULTI_IRQ_HANDLER
handle_arch_irq = mdesc->handle_irq;
#endif

#ifdef CONFIG_VT
#if defined(CONFIG_VGA_CONSOLE)
Expand Down

0 comments on commit d38d2ab

Please sign in to comment.