/**	errcodes.h
 **
 ** Author: Ted Schmitz
 ** Date of original creation December 8, 2008
 **
 ** This file defines all the error stops and suplimental error stops used
 ** in the low-level switch POST tests.   The proper error codes file is
 ** included wit this file at compile time.
 **
 **	Error codes are made up of two parts: 
 ** 1) The 16-bit error stop
 ** 2) The 16-bit supplimental error stop
 **
 **	There are many tests that share common verification code, therefore, 
 ** it is possible for different tests to fail with the same malfunction.  For 
 ** this reason each test uses a unique set of error codes called error stops 
 ** and each common test routine uses a separate set of error codes called 
 ** supplementary error stops.  By allowing each test to use a unique set of 
 ** error stops, we are guaranteeing that no error stops will ever have to 
 ** change even if test numbers change as tests are added, deleted, or
 ** rearrange.  Test numbers will then be used only to manage testing and 
 ** display current statistics.
 **
 **	If the supplementary error stop is zero the error stop portion of the
 ** error code describes the exact problem that caused the failure.  If the
 ** supplementary error stop is non-zero the error stop portion of the error 
 ** code describes the test that was underway when the malfunction was
 ** detected and the supplementary error stop portion then defines the exact 
 ** problem that caused the error to be displayed.  In either case the entire 
 ** 32-bit error code must be analyzed to fully understand what failed on the 
 ** board.  
 **
 **	Both parts of each error code are defined in this file in separate
 ** sections.  The first section defines the error stops.  The supplimental
 ** error stops are defined last.
 **
 ** 	As mentioned above, test numbers may change as tests are added,
 ** deleted, or rearrange, however, the 32-bit error codes will never change
 ** as described under the rules below.
 **
 **	RULES FOR ALL ERROR CODES!
 **
 ** 1 - When a new error code is required, the following format may be used
 **     to define the new error stop: ESnnnn.  nnnn is the actual value of
 **     the new error stop.  
 **     If a new supplemental error stop is defined, the following format
 **     may be used: SESnnnn. nnnn is the actual value of the new
 **     supplemental error stop.
 ** 2 - NEVER delete an old error stop or supplemental error stop!.  If an
 **     error stop is no longer needed is should be obsoleted by commenting
 **     it out of this code and adding a comment defining it as obsoleted.  
 **     Obsoleted error stops should never be used again.
 ** 3 - As described above, obsoleted error stops should never be used again!
 **     Once people get used to certain error codes, we do not want to be 
 **     changing them.  For this reason we never use an old error code for
 **     something new or re-assign error codes for any reason.
 ** 4 - ALWAYS PUT ALL ERROR CODES IN ONE HEADER FILE FOR EACH PLATFORM!!!!
 **     Never spread your error codes over more than one file.  This has
 **     the potential to have one error code assigned to more than one
 **     error stop. (This has actually happened once already).
 ** 5 - ALWAYS list error codes in numerical order in the header file!
 **     Even if the error code has an alias it should still be list in 
 **     order by its actual error code value not by its alias.  This way 
 **     you can quickly check to see if an error code is currently in use.
 **     This method also significantly reduces the human error when 
 **     looking for a value in a large list of candidates.
 **
 **   Date   INTLS Comments
 ** -------- ----- --------------------------------------------
 ** 06-29-09  TMS  Added support for TNPA-5651x board.
 **
 **/
#ifndef __ERRCODES_H__
#define __ERRCODES_H__

#define NO_ERROR_CODES

/* Compile for NPA-56x4 AMC platform */
#ifdef octeon_tnpa56x4
#include "npa_56x4_errcodes.h"
#undef NO_ERROR_CODES
#endif

/* compile for NPA-5651x AMC board */
#ifdef octeon_tnpa5651x
#include "npa_5651x_errcodes.h"
#undef NO_ERROR_CODES
#endif

#ifdef NO_ERROR_CODES
#error "ERROR! No POST error codes defined for this platform!!"
#endif

#endif  /* __ERRCODES_H__ */
