⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 excarchshow.c

📁 VxWorks BSP框架源代码包含头文件和驱动
💻 C
📖 第 1 页 / 共 2 页
字号:
/* excArchShow.c - PowerPC exception show facilities *//* Copyright 1984-2002 Wind River Systems, Inc. */#include "copyright_wrs.h"/*modification history--------------------01w,13aug03,mil  Added machine check related info.01v,22nov02,mil  Updated support for PPC85XX.01u,03aug02,pcs  Add support for PPC85XX and make it the same as PPC603 for                 the present.01t,16may02,mil  Added _EXC_OFF_THERMAL for PPC604 (SPR #77552).01s,19apr02,jtp  Correct display of excMsgTbl[] for PPC44001r,30oct01,pch  Fix spelling errors in reports01q,16aug01,pch  Add support for PPC44001p,14jun01,kab  Fixed Altivec Unavailable Exchandler, SPR 6820601o,30nov00,s_m  added showing of BEAR for 40501n,25oct00,s_m  renamed PPC405 cpu types01m,13oct00,sm   modified machine check handling for PPC40501l,06oct00,sm   PPC405 support01k,12aug99,zl   added PowerPC 509 and PowerPC 555 support.01j,18aug98,tpr  added PowerPC EC 603 support.01i,24feb97,tam  added support for 403GC/GCX exceptions.01h,10feb97,tam  added support to handle floating point exceptions (SPR #7840).01g,24may96,tpr  added PowerPC 860 support.01f,15mar96,tam  added PPC403 support.01e,23feb96,tpr  cleaned up.01d,14feb96,tpr  split PPC603 and PPC604.01c,03oct95,tpr  changed %d to 0x%x in excInfoShow().01b,03mar95,yao  added NIA message.  added modification history.01a,xxxxxxx,yao  created.*//*This module contains PowerPC architecture dependent portions of theexception handling facilities.  See excLib for the portions that arearchitecture independent.SEE ALSO: dbgLib, sigLib, intLib, "Debugging"*/#include "vxWorks.h"#include "esf.h"#include "iv.h"#include "taskLib.h"#include "errno.h"#include "string.h"#include "logLib.h"#include "stdio.h"#include "stdio.h"#include "fioLib.h"#include "vxLib.h"#include "private/funcBindP.h"#ifdef _WRS_ALTIVEC_SUPPORT#include "altivecLib.h"#endif /* _WRS_ALTIVEC_SUPPORT */typedef struct {    int		excVec;		/* exception vector */    char * 	excMsg;		/* exception message */    } EXC_MSG_TBL;/* locals *//*  * Exception error messages.  These are used by the exception printing routine. * Exception numbers are the same as used by the CPU */LOCAL EXC_MSG_TBL excMsgTbl [] = {#if  ((CPU==PPC403) || (CPU == PPC405) || (CPU == PPC405F) || \      (CPU == PPC440) || (CPU == PPC85XX))# ifdef	   _EXC_OFF_CRTL	  {_EXC_OFF_CRTL, "critical interrupt"},# endif	/* _EXC_OFF_CRTL */# ifdef	   _EXC_OFF_MACH	  {_EXC_OFF_MACH, "machine check"},# endif	/* _EXC_OFF_MACH */# ifdef	   _EXC_OFF_DATA	  {_EXC_OFF_DATA, "data storage"},# endif	/* _EXC_OFF_DATA */# ifdef	   _EXC_OFF_PROT	  {_EXC_OFF_PROT, "protection violation/data access"},# endif	/* _EXC_OFF_PROT */# ifdef	   _EXC_OFF_INST	  {_EXC_OFF_INST, "instruction access"},# endif	/* _EXC_OFF_INST */# ifdef	   _EXC_OFF_INTR	  {_EXC_OFF_INTR, "external interrupt"},# endif	/* _EXC_OFF_INTR */# ifdef	   _EXC_OFF_ALIGN	  {_EXC_OFF_ALIGN, "alignment"},# endif	/* _EXC_OFF_ALIGN */# ifdef	   _EXC_OFF_PROG	  {_EXC_OFF_PROG, "program"},# endif	/* _EXC_OFF_PROG */# ifdef	   _EXC_OFF_FPU	  {_EXC_OFF_FPU, "fp unavailable"},# endif	/* _EXC_OFF_FPU */# ifdef	   _EXC_OFF_SYSCALL	  {_EXC_OFF_SYSCALL, "system call"},# endif	/* _EXC_OFF_SYSCALL */# ifdef	   _EXC_OFF_APU	  {_EXC_OFF_APU, "auxiliary processor unavailable"},# endif	/* _EXC_OFF_APU */# ifdef	   _EXC_OFF_DECR	  {_EXC_OFF_DECR, "decrementer"},# endif	/* _EXC_OFF_DECR */# ifdef	   _EXC_OFF_PIT	  {_EXC_OFF_PIT, "programmable interval timer"},# endif	/* _EXC_OFF_PIT */# ifdef	   _EXC_OFF_FIT	  {_EXC_OFF_FIT, "fixed interval timer"},# endif	/* _EXC_OFF_FIT */# ifdef	   _EXC_OFF_WD	  {_EXC_OFF_WD, "watchdog timer"},# endif	/* _EXC_OFF_WD */# ifdef	   _EXC_OFF_DATA_MISS	  {_EXC_OFF_DATA_MISS, "data translation miss"},# endif	/* _EXC_OFF_DATA_MISS */# ifdef	   _EXC_OFF_INST_MISS	  {_EXC_OFF_INST_MISS, "instruction translation miss"},# endif	/* _EXC_OFF_INST_MISS */# ifdef	   _EXC_OFF_DBG	  {_EXC_OFF_DBG, "debug exception"},# endif	/* _EXC_OFF_DBG */# ifdef	   _EXC_OFF_SPE	  {_EXC_OFF_SPE, "SPE unavailable exception"},# endif	/* _EXC_OFF_SPE */# ifdef	   _EXC_OFF_VEC_DATA	  {_EXC_OFF_VEC_DATA, "SPE vector data exception"},# endif	/* _EXC_OFF_VEC_DATA */# ifdef	   _EXC_OFF_VEC_RND	  {_EXC_OFF_VEC_RND, "SPE vector rounding exception"},# endif	/* _EXC_OFF_VEC_RND */# ifdef	   _EXC_OFF_PERF_MON	  {_EXC_OFF_PERF_MON, "Performance monitor exception"},# endif	/* _EXC_OFF_PERF_MON */#endif	/* CPU==PPC4xx, PPC85XX */#if	(CPU == PPC509)     {_EXC_OFF_RESET, "system reset"},    {_EXC_OFF_MACH, "machine check"},    {_EXC_OFF_INTR, "external interrupt"},    {_EXC_OFF_ALIGN, "alignment"},    {_EXC_OFF_PROG, "program"},    {_EXC_OFF_FPU, "fp unavailable"},    {_EXC_OFF_DECR, "decrementer"},    {_EXC_OFF_SYSCALL, "system call"},    {_EXC_OFF_TRACE, "trace"},    {_EXC_OFF_FPA, "floating point assist"},    {_EXC_OFF_SW_EMUL, "Implementation Dependent Software Emulation"},    {_EXC_OFF_DATA_BKPT, "Implementation Dependent Data Breakpoint "},    {_EXC_OFF_INST_BKPT, "Implementation Dependent Instruction Breakpoint"},    {_EXC_OFF_PERI_BKPT, "Implementation Dependent Peripheral Breakpoint"},    {_EXC_OFF_NM_DEV_PORT, "Implementation Dependent Non Maskable Development Port"},#endif	/* (CPU == PPC509) */#if	(CPU == PPC555)     {_EXC_OFF_RESET, "system reset"},    {_EXC_OFF_MACH, "machine check"},    {_EXC_OFF_INTR, "external interrupt"},    {_EXC_OFF_ALIGN, "alignment"},    {_EXC_OFF_PROG, "program"},    {_EXC_OFF_FPU, "fp unavailable"},    {_EXC_OFF_DECR, "decrementer"},    {_EXC_OFF_SYSCALL, "system call"},    {_EXC_OFF_TRACE, "trace"},    {_EXC_OFF_FPA, "floating point assist"},    {_EXC_OFF_SW_EMUL, "Implementation Dependent Software Emulation"},    {_EXC_OFF_IPE, "Implementation Dependent Instruction Protection Error"},    {_EXC_OFF_DPE, "Implementation Dependent Data Protection Error"},    {_EXC_OFF_DATA_BKPT, "Implementation Dependent Data Breakpoint "},    {_EXC_OFF_INST_BKPT, "Implementation Dependent Instruction Breakpoint"},    {_EXC_OFF_PERI_BKPT, "Implementation Dependent Peripheral Breakpoint"},    {_EXC_OFF_NM_DEV_PORT, "Implementation Dependent Non Maskable Development Port"},#endif	/* (CPU == PPC555) */#if	(CPU==PPC601)    {_EXC_OFF_RESET, "system reset"},    {_EXC_OFF_MACH, "machine check"},    {_EXC_OFF_DATA, "data access"},    {_EXC_OFF_INST, "instruction access"},    {_EXC_OFF_INTR, "external interrupt"},    {_EXC_OFF_ALIGN, "alignment"},    {_EXC_OFF_PROG, "program"},    {_EXC_OFF_FPU, "fpu unavailable"},    {_EXC_OFF_DECR, "decrementer"},    {_EXC_OFF_SYSCALL, "system call"},    {_EXC_OFF_IOERR, "io controller interface error"},    {_EXC_OFF_RUN_TRACE, "run mode/trace"},#endif	/* (CPU==PPC601) */#if	((CPU == PPC603) || (CPU == PPCEC603))    {_EXC_OFF_RESET, "system reset"},    {_EXC_OFF_MACH, "machine check"},    {_EXC_OFF_DATA, "data access"},    {_EXC_OFF_INST, "instruction access"},    {_EXC_OFF_INTR, "external interrupt"},    {_EXC_OFF_ALIGN, "alignment"},    {_EXC_OFF_PROG, "program"},    {_EXC_OFF_FPU, "fp unavailable"},    {_EXC_OFF_DECR, "decrementer"},    {_EXC_OFF_SYSCALL, "system call"},    {_EXC_OFF_TRACE, "trace"},    {_EXC_OFF_INST_MISS, "instruction translation miss"},    {_EXC_OFF_LOAD_MISS, "data load translation miss"},    {_EXC_OFF_STORE_MISS, "data store translation miss"},    {_EXC_OFF_INST_BRK, "instruction address breakpoint exception"},    {_EXC_OFF_SYS_MNG, "system management interrupt"},#endif	/* ((CPU == PPC603) || (CPU == PPCEC6030)) */#if	(CPU == PPC604)     {_EXC_OFF_RESET, "system reset"},    {_EXC_OFF_MACH, "machine check"},    {_EXC_OFF_DATA, "data access"},    {_EXC_OFF_INST, "instruction access"},    {_EXC_OFF_INTR, "external interrupt"},    {_EXC_OFF_ALIGN, "alignment"},    {_EXC_OFF_PROG, "program"},    {_EXC_OFF_FPU, "fp unavailable"},    {_EXC_OFF_DECR, "decrementer"},    {_EXC_OFF_SYSCALL, "system call"},    {_EXC_OFF_TRACE, "trace"},    {_EXC_OFF_PERF, "performance monitoring"},# ifdef _WRS_ALTIVEC_SUPPORT    {_EXC_ALTIVEC_UNAVAILABLE, "AltiVec unavailable"},    {_EXC_ALTIVEC_ASSIST, "AltiVec assist"},# endif /* _WRS_ALTIVEC_SUPPORT */    {_EXC_OFF_INST_BRK, "instruction address breakpoint exception"},    {_EXC_OFF_SYS_MNG, "system management interrupt"},    {_EXC_OFF_THERMAL, "thermal"},#endif	/* (CPU == PPC604) */#if	(CPU == PPC860)     {_EXC_OFF_RESET, "system reset"},    {_EXC_OFF_MACH, "machine check"},    {_EXC_OFF_DATA, "data access"},    {_EXC_OFF_INST, "instruction access"},    {_EXC_OFF_INTR, "external interrupt"},    {_EXC_OFF_ALIGN, "alignment"},    {_EXC_OFF_PROG, "program"},    {_EXC_OFF_FPU, "fp unavailable"},

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -