00001 /*--------------------------------------------------------------------------------- 00002 00003 Copyright (C) 2005 00004 Dave Murphy (WinterMute) 00005 00006 This software is provided 'as-is', without any express or implied 00007 warranty. In no event will the authors be held liable for any 00008 damages arising from the use of this software. 00009 00010 Permission is granted to anyone to use this software for any 00011 purpose, including commercial applications, and to alter it and 00012 redistribute it freely, subject to the following restrictions: 00013 00014 1. The origin of this software must not be misrepresented; you 00015 must not claim that you wrote the original software. If you use 00016 this software in a product, an acknowledgment in the product 00017 documentation would be appreciated but is not required. 00018 2. Altered source versions must be plainly marked as such, and 00019 must not be misrepresented as being the original software. 00020 3. This notice may not be removed or altered from any source 00021 distribution. 00022 00023 ---------------------------------------------------------------------------------*/ 00024 #ifndef _exceptions_h_ 00025 #define _exceptions_h_ 00026 //--------------------------------------------------------------------------------- 00027 00028 #define EXCEPTION_VECTOR (*(VoidFn *)(0x2FFFD9C)) 00029 00030 00031 extern VoidFn exceptionC[]; 00032 extern u32 exceptionStack; 00033 extern s32 exceptionRegisters[]; 00034 00035 void enterException(void); 00036 void setExceptionHandler(VoidFn handler); 00037 void defaultExceptionHandler(); 00038 00039 u32 getCPSR(); 00040 00041 //--------------------------------------------------------------------------------- 00042 #endif // _exceptions_h_ 00043 //---------------------------------------------------------------------------------