提交 ef300e42 编写于 作者: R Ralf Baechle

[MIPS] Define and use vi_handler_t for vectored interrupt handlers.

Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
上级 856a514b
...@@ -1128,7 +1128,7 @@ void mips_srs_free(int set) ...@@ -1128,7 +1128,7 @@ void mips_srs_free(int set)
clear_bit(set, &sr->sr_allocated); clear_bit(set, &sr->sr_allocated);
} }
static void *set_vi_srs_handler(int n, void *addr, int srs) static void *set_vi_srs_handler(int n, vi_handler_t addr, int srs)
{ {
unsigned long handler; unsigned long handler;
unsigned long old_handler = vi_handlers[n]; unsigned long old_handler = vi_handlers[n];
...@@ -1217,7 +1217,7 @@ static void *set_vi_srs_handler(int n, void *addr, int srs) ...@@ -1217,7 +1217,7 @@ static void *set_vi_srs_handler(int n, void *addr, int srs)
return (void *)old_handler; return (void *)old_handler;
} }
void *set_vi_handler(int n, void *addr) void *set_vi_handler(int n, vi_handler_t addr)
{ {
return set_vi_srs_handler(n, addr, 0); return set_vi_srs_handler(n, addr, 0);
} }
......
...@@ -464,7 +464,10 @@ static inline unsigned long __cmpxchg_local(volatile void * ptr, ...@@ -464,7 +464,10 @@ static inline unsigned long __cmpxchg_local(volatile void * ptr,
extern void set_handler (unsigned long offset, void *addr, unsigned long len); extern void set_handler (unsigned long offset, void *addr, unsigned long len);
extern void set_uncached_handler (unsigned long offset, void *addr, unsigned long len); extern void set_uncached_handler (unsigned long offset, void *addr, unsigned long len);
extern void *set_vi_handler (int n, void *addr);
typedef void (*vi_handler_t)(void);
extern void *set_vi_handler (int n, vi_handler_t addr);
extern void *set_except_vector(int n, void *addr); extern void *set_except_vector(int n, void *addr);
extern unsigned long ebase; extern unsigned long ebase;
extern void per_cpu_trap_init(void); extern void per_cpu_trap_init(void);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册