]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blame - arch/arm/include/asm/traps.h
irq: Make the irqentry text section unconditional
[mirror_ubuntu-bionic-kernel.git] / arch / arm / include / asm / traps.h
CommitLineData
1da177e4
LT
1#ifndef _ASMARM_TRAP_H
2#define _ASMARM_TRAP_H
3
4#include <linux/list.h>
5
e7d59db9
MP
6struct pt_regs;
7struct task_struct;
8
1da177e4
LT
9struct undef_hook {
10 struct list_head node;
11 u32 instr_mask;
12 u32 instr_val;
13 u32 cpsr_mask;
14 u32 cpsr_val;
15 int (*fn)(struct pt_regs *regs, unsigned int instr);
16};
17
18void register_undef_hook(struct undef_hook *hook);
19void unregister_undef_hook(struct undef_hook *hook);
20
61b5cb1c
RV
21static inline int __in_irqentry_text(unsigned long ptr)
22{
23 extern char __irqentry_text_start[];
24 extern char __irqentry_text_end[];
25
26 return ptr >= (unsigned long)&__irqentry_text_start &&
27 ptr < (unsigned long)&__irqentry_text_end;
28}
61b5cb1c 29
785d3cd2
NP
30static inline int in_exception_text(unsigned long ptr)
31{
32 extern char __exception_text_start[];
33 extern char __exception_text_end[];
61b5cb1c
RV
34 int in;
35
36 in = ptr >= (unsigned long)&__exception_text_start &&
37 ptr < (unsigned long)&__exception_text_end;
785d3cd2 38
61b5cb1c 39 return in ? : __in_irqentry_text(ptr);
785d3cd2
NP
40}
41
94e5a85b 42extern void __init early_trap_init(void *);
67a94c23 43extern void dump_backtrace_entry(unsigned long where, unsigned long from, unsigned long frame);
425fc47a 44extern void ptrace_break(struct task_struct *tsk, struct pt_regs *regs);
5cbad0eb 45
247055aa
CM
46extern void *vectors_page;
47
1da177e4 48#endif