1/* 2 * Copyright (C) 2005,2008 Imagination Technologies 3 * 4 * This file is subject to the terms and conditions of the GNU General Public 5 * License. See the file COPYING in the main directory of this archive 6 * for more details. 7 */ 8 9#ifndef _METAG_TBIVECTORS_H 10#define _METAG_TBIVECTORS_H 11 12#ifndef __ASSEMBLY__ 13 14#include <asm/tbx.h> 15 16typedef TBIRES (*kick_irq_func_t)(TBIRES, int, int, int, PTBI, int *); 17 18extern TBIRES kick_handler(TBIRES, int, int, int, PTBI); 19struct kick_irq_handler { 20 struct list_head list; 21 kick_irq_func_t func; 22}; 23 24extern void kick_register_func(struct kick_irq_handler *); 25extern void kick_unregister_func(struct kick_irq_handler *); 26 27extern void head_end(TBIRES, unsigned long); 28extern void restart_critical_section(TBIRES State); 29extern TBIRES tail_end_sys(TBIRES, int, int *); 30static inline TBIRES tail_end(TBIRES state) 31{ 32 return tail_end_sys(state, -1, NULL); 33} 34 35DECLARE_PER_CPU(PTBI, pTBI); 36extern PTBI pTBI_get(unsigned int); 37 38extern int ret_from_fork(TBIRES arg); 39 40extern int do_page_fault(struct pt_regs *regs, unsigned long address, 41 unsigned int write_access, unsigned int trapno); 42 43extern TBIRES __TBIUnExpXXX(TBIRES State, int SigNum, int Triggers, int Inst, 44 PTBI pTBI); 45 46#endif 47 48#endif /* _METAG_TBIVECTORS_H */ 49