exception.h 706 字节
Newer Older
B
Bernard Xiong 已提交
1
/*
J
Jiaxun Yang 已提交
2
 * Copyright (c) 2006-2019, RT-Thread Development Team
B
Bernard Xiong 已提交
3
 *
J
Jiaxun Yang 已提交
4
 * SPDX-License-Identifier: Apache-2.0
B
Bernard Xiong 已提交
5 6 7
 *
 * Change Logs:
 * Date           Author       Notes
J
Jiaxun Yang 已提交
8
 * 2019-12-04     Jiaxun Yang  Initial version
B
Bernard Xiong 已提交
9
 */
J
Jiaxun Yang 已提交
10

B
Bernard Xiong 已提交
11 12 13
#ifndef __EXCEPTION_H__
#define __EXCEPTION_H__

J
Jiaxun Yang 已提交
14
#include "ptrace.h"
B
Bernard Xiong 已提交
15

J
Jiaxun Yang 已提交
16
#ifndef __ASSEMBLY__
B
Bernard Xiong 已提交
17

J
Jiaxun Yang 已提交
18
typedef void (* exception_func_t)(struct pt_regs *regs);
B
Bernard Xiong 已提交
19

J
Jiaxun Yang 已提交
20
extern int rt_hw_exception_init(void);
B
Bernard Xiong 已提交
21
extern exception_func_t sys_exception_handlers[];
J
Jiaxun Yang 已提交
22
extern void rt_do_mips_cpu_irq(rt_uint32_t ip);
B
Bernard Xiong 已提交
23
exception_func_t rt_set_except_vector(int n, exception_func_t func);
J
Jiaxun Yang 已提交
24 25 26
extern void mips_mask_cpu_irq(rt_uint32_t irq);
extern void mips_unmask_cpu_irq(rt_uint32_t irq);
#endif
B
Bernard Xiong 已提交
27 28

#endif /* end of __EXCEPTION_H__ */