XilinxProcessorIPLib/drivers/aiengine/src/tile/xaietile_error.c
static u32 XAieTile_ErrorsDefaultLog(u8 Module, u8 Error)
{
	if (Module == XAIEGBL_MODULE_CORE) {
		switch (Error) {
		case XAIETILE_EVENT_CORE_SRS_SATURATE:
		case XAIETILE_EVENT_CORE_UPS_SATURATE:
		case XAIETILE_EVENT_CORE_FP_OVERFLOW:
		case XAIETILE_EVENT_CORE_FP_UNDERFLOW:
		case XAIETILE_EVENT_CORE_FP_INVALID:
		case XAIETILE_EVENT_CORE_FP_DIV_BY_ZERO:
		case XAIETILE_EVENT_CORE_PM_ECC_ERROR_SCRUB_CORRECTED:
		case XAIETILE_EVENT_CORE_PM_ECC_ERROR_SCRUB_2BIT:
		case XAIETILE_EVENT_CORE_PM_ECC_ERROR_1BIT:
		case XAIETILE_EVENT_CORE_INSTR_WARNING:
		case XAIETILE_EVENT_CORE_INSTR_ERROR:
			return 0;
		default:
			return 1;
		}
	} else if (Module == XAIEGBL_MODULE_MEM) {
		switch (Error) {
		case XAIETILE_EVENT_MEM_DM_ECC_ERROR_SCRUB_CORRECTED:
		case XAIETILE_EVENT_MEM_DM_ECC_ERROR_SCRUB_2BIT:
		case XAIETILE_EVENT_MEM_DM_ECC_ERROR_1BIT:
			return 0;
		default:
			return 1;
		}
	} else {
		return 1;
	}
}
/************************** Internal Function Definitions ********************/
/*****************************************************************************/
/**
 * This API checks if the error needs logging by default.
 *
 * @param	Module - Module type
 *			XAIEGBL_MODULE_CORE, XAIEGBL_MODULE_PL,
 *			XAIEGBL_MODULE_MEM
 * @param	Error - Error event id
 *			48 - 69 for Core module
 *			87 - 100 for Memory module
 *			62 - 72 for SHIM PL module
 *
 * @return	1 for logging required by default, 0 for no action required
 *		by default.
 * @note	As the function is called internally, it will not validate
 *		the module nor the errors assuming the caller will do the
 *		validation.
 *
 *		Used only within this file.
 *****************************************************************************/
Internal Function Definitions
This API checks if the error needs logging by default.



@return      1 for logging required by default, 0 for no action required
by default.
@note        As the function is called internally, it will not validate
the module nor the errors assuming the caller will do the
validation.

Used only within this file.
Internal Function Definitions This API checks if the error needs logging by default . @return 1 for logging required by default 0 for no action required by default . @note As the function is called internally it will not validate the module nor the errors assuming the caller will do the validation . Used only within this file .
static u32 XAieTile_ErrorsDefaultLog(u8 Module, u8 Error)
{
	if (Module == XAIEGBL_MODULE_CORE) {
		switch (Error) {
		case XAIETILE_EVENT_CORE_SRS_SATURATE:
		case XAIETILE_EVENT_CORE_UPS_SATURATE:
		case XAIETILE_EVENT_CORE_FP_OVERFLOW:
		case XAIETILE_EVENT_CORE_FP_UNDERFLOW:
		case XAIETILE_EVENT_CORE_FP_INVALID:
		case XAIETILE_EVENT_CORE_FP_DIV_BY_ZERO:
		case XAIETILE_EVENT_CORE_PM_ECC_ERROR_SCRUB_CORRECTED:
		case XAIETILE_EVENT_CORE_PM_ECC_ERROR_SCRUB_2BIT:
		case XAIETILE_EVENT_CORE_PM_ECC_ERROR_1BIT:
		case XAIETILE_EVENT_CORE_INSTR_WARNING:
		case XAIETILE_EVENT_CORE_INSTR_ERROR:
			return 0;
		default:
			return 1;
		}
	} else if (Module == XAIEGBL_MODULE_MEM) {
		switch (Error) {
		case XAIETILE_EVENT_MEM_DM_ECC_ERROR_SCRUB_CORRECTED:
		case XAIETILE_EVENT_MEM_DM_ECC_ERROR_SCRUB_2BIT:
		case XAIETILE_EVENT_MEM_DM_ECC_ERROR_1BIT:
			return 0;
		default:
			return 1;
		}
	} else {
		return 1;
	}
}
static u32 XAieTile_ErrorsDefaultLog ( u8 Module , u8 Error ) { if ( Module == XAIEGBL_MODULE_CORE ) { switch ( Error ) { case XAIETILE_EVENT_CORE_SRS_SATURATE : case XAIETILE_EVENT_CORE_UPS_SATURATE : case XAIETILE_EVENT_CORE_FP_OVERFLOW : case XAIETILE_EVENT_CORE_FP_UNDERFLOW : case XAIETILE_EVENT_CORE_FP_INVALID : case XAIETILE_EVENT_CORE_FP_DIV_BY_ZERO : case XAIETILE_EVENT_CORE_PM_ECC_ERROR_SCRUB_CORRECTED : case XAIETILE_EVENT_CORE_PM_ECC_ERROR_SCRUB_2BIT : case XAIETILE_EVENT_CORE_PM_ECC_ERROR_1BIT : case XAIETILE_EVENT_CORE_INSTR_WARNING : case XAIETILE_EVENT_CORE_INSTR_ERROR : return 0 ; default : return 1 ; } } else if ( Module == XAIEGBL_MODULE_MEM ) { switch ( Error ) { case XAIETILE_EVENT_MEM_DM_ECC_ERROR_SCRUB_CORRECTED : case XAIETILE_EVENT_MEM_DM_ECC_ERROR_SCRUB_2BIT : case XAIETILE_EVENT_MEM_DM_ECC_ERROR_1BIT : return 0 ; default : return 1 ; } } else { return 1 ; } }
Internal Function Definitions
 This API checks if the error needs logging by default.
Internal Function Definitions This API checks if the error needs logging by default .