rheatest.h

来自「OMAP1030 处理器的ARM 侧硬件测试代码 OMAP1030 是TI」· C头文件 代码 · 共 227 行

H
227
字号
/*
===============================================================================
            TEXAS INSTRUMENTS INCORPORATED PROPRIETARY INFORMATION           
                                                                             
   Property of Texas Instruments 
   For  Unrestricted  Internal  Use  Only 
   Unauthorized reproduction and/or distribution is strictly prohibited.  
   This product is protected under copyright law and trade secret law 
   as an unpublished work.  
   Created 1999, (C) Copyright 1999 Texas Instruments.  All rights reserved.

   Filename       	: RheaTest.h
   Description    	: Spec file for the test of ARM to Rhea Bridge module
   Project        	: Satustar
   Author         	: Francois Reygagne freygagn@tif.ti.com

===============================================================================
*/
#ifndef _RHEATEST__HH
#define _RHEATEST__HH

#include "top.h"
#include "dma.h"
#include "rheabridge.h"

/*
--------------------------------------------------------------------
 NAME        : RHEATEST_multiple_store_load                        -
 DESCRIPTION : Multiple store and load stmia/ldmia assembler test  
               on 32 bits memory		                               -
               Check back the values                               -
 PARAMETERS  : Address of the fast and slow strobes used           -
 RETURN VALUE: RES_OK on success otherwise RES_BAD                 -
 LIMITATIONS : None                                                -
--------------------------------------------------------------------
*/
UWORD16 RHEATST_MultipleStoreLoad32Bits (UWORD32 Strobe0Address,
                                             UWORD32 Strobe1Address);

/*
-----------------------------------------------------------
 NAME        : rheatest_LowFrequency
 DESCRIPTION : Test with low frequency on bridge
 PARAMETERS  : Address on strobe 0 & 1 to perform test  
 					kind of memory
 RETURN VALUE: Return the operation status value          
 LIMITATIONS : Should be use with system clock set to low frequency (13 Mhz)
-----------------------------------------------------------
*/
UWORD16 RHEATST_LowFrequency(UWORD32 Strobe0Address,
                               UWORD32 Strobe1Address,
		  								const RHEA_Access_Size_t MemoryWidth) ;

/*
-----------------------------------------------------------
 NAME        : RHEATST_AccessFactor
 DESCRIPTION : Test the access factors and Bank Switching -
               The idea is to alternate the write accesses-
               between the fast and slow strobes.         -
 PARAMETERS  : Address of the fast and slow strobes used  -
 					memory width for type of access 8,16 or 32 bits
 RETURN VALUE: Return the operation status value          -
 LIMITATIONS : None                                       -
-----------------------------------------------------------
*/
UWORD16 RHEATST_AccessFactor(UWORD32 Strobe0Address,
                                  UWORD32 Strobe1Address,
											 const RHEA_Access_Size_t MemoryWidth); 

/*
--------------------------------------------------------------------
 NAME        : RHEATEST_write                                -
 DESCRIPTION : Program a right access using the write buffer       -
               on fast strobe 0. The Write Buffer supports the     -
               creation of asynchronous function Posted Write      -
               that can return to his caller before the operation  -
               write has finished.                                 -
               Wait for the result of the posted write operation.  -
               If posted write operation has not yet completed,    -
               reading back is blocked until a result is produced. -
 PARAMETERS  : Strobe0Address: fast strobe address where to write  -
               Strobe1Address: slow strobe address where to write  -
 RETURN VALUE: RES_OK on success otherwise RES_BAD (ref Result.h)  -
 LIMITATIONS : Use the memory base strobe address in the range     -
               RHEA_STROBE0_CS0_ADDR .. RHEA_STROBE0_CS31_ADDR     -
               RHEA_STROBE1_CS0_ADDR .. RHEA_STROBE1_CS31_ADDR     -
--------------------------------------------------------------------
*/
UWORD16 RHEATST_WriteBuffer (UWORD32 Strobe0Address,
                              UWORD32 Strobe1Address,
		  								const RHEA_Access_Size_t MemoryWidth);


/*
---------------------------------------------------------------------------
 NAME        : RHEATST_Write8Bits                                       -
 DESCRIPTION : Write bytes on Rhea CS strobe 0 and 1							  -
               In each case, re-read them                                 -
               and check that the value is correct                        -
 PARAMETERS  :                                                            -
   INPUT =>                                                               -
            Strobe0adress : Address on strobe 0									  -
            Strobe1adress : Address on strobe 1									  -
 RETURN VALUE: Result (0 for not-tried, 1 for OK, 2 for bad)              -
 LIMITATIONS : Memory should be 8 bits wide.                                                      -
---------------------------------------------------------------------------
*/
UWORD16 RHEATST_Write8Bits(UWORD32 Strobe0Address,UWORD32 Strobe1Address);
/*
---------------------------------------------------------------------------
 NAME        : RHEATST_Write16Bits                                      -
 DESCRIPTION : Write half words on Rhea CS strobe 0 and 1					  -
               In each case, re-read them                                 -
               and check that the value is correct                        -
 PARAMETERS  :                                                            -
   INPUT =>                                                               -
            Strobe0adress : Address on strobe 0									  -
            Strobe1adress : Address on strobe 1									  -
 RETURN VALUE: Result (0 for not-tried, 1 for OK, 2 for bad)              -
 LIMITATIONS : Memory should be 16 bits wide.                                                      -
---------------------------------------------------------------------------
*/
UWORD16 RHEATST_Write16Bits(UWORD32 Strobe0Address,UWORD32 Strobe1Address);
/*
---------------------------------------------------------------------------
 NAME        : RHEATST_Write32Bits                                      -
 DESCRIPTION : Write words on Rhea CS strobe 0 and 1							  -
               In each case, re-read them                                 -
               and check that the value is correct                        -
 PARAMETERS  :                                                            -
   INPUT =>                                                               -
            Strobe0adress : Address on strobe 0									  -
            Strobe1adress : Address on strobe 1									  -
 RETURN VALUE: Result (0 for not-tried, 1 for OK, 2 for bad)              -
 LIMITATIONS : Memory should be 32 bits wide.                                                      -
---------------------------------------------------------------------------
*/
UWORD16 RHEATST_Write32Bits(UWORD32 Strobe0Address,UWORD32 Strobe1Address);
/*
------------------------------------------------------------------------
	RHEATEST_fast_store_load
------------------------------------------------------------------------
*/
UWORD16  RHEATST_FastStoreLoadOn32Bits(UWORD32 Strobe0Address,UWORD32 Strobe1Address);  




/*
----------------------------------------------------------------------
 NAME        : RHEATEST_BusAllocation                                -
 DESCRIPTION : Make the DMA with a priority of 7 and ARM processing  -
               huge transfer simultaneously                          -
               Program a right access using the write buffer on fast -
               strobe 0 only since DMA has no access on strobe 1.    -
               Check the data are correctly written, i.e no data     -
               interleave occurs.                                    -
 PARAMETERS  : EMifSrcAdress : Adress origin of transfert in slow 
                               interface memory area                                          
             : RheaChipSelect : Cs select for strobe 0 rhea mapping
             : RheaDstAddress : destination address in rhea 
 RETURN VALUE: Result (0 for not-tried, 1 for OK, 2 for bad)              -
 LIMITATIONS : EmifSrcAdress must be in slow CS config (not SDRAM area or internal ram ) 
             : RheaChipSelect and RheaDstAddress should be attached to strobe 0
				   No DMA transfert on strobe 1 
----------------------------------------------------------------------
*/
UWORD16 rheatest_dma_priority (UWORD32 				  emif_src_address,
                            RHEA_Strobe0ChipSelect_t rhea_dst_chipselect,
									 UWORD32 			     rhea_dst_address,
									 UWORD16 					  size_in_bytes);    


/*
-------------------------------------------------------------------------
 NAME        : RHEATEST_TimeOut                                         -
 DESCRIPTION : Program a right access using a timeout                   -
               to a missing peripheral                                  -
 PARAMETERS  :                                                          -
   Strobe0Address,Strobe1Address : strobe address where to write & read -
   TimeOutCounter: This counter is incremented for each raised TimeOut  -
                   in the interrupt routine                                 
 RETURN VALUE: RES_OK on success otherwise RES_BAD  (refer Result.h)    -
 LIMITATIONS : Specify a strobe address not connected to any peripheral -
               IRQ and FIQ must be enabled                              -
-------------------------------------------------------------------------
*/

void RHEATST_Timeout (UWORD32 Strobe0Address,
                          UWORD32 Strobe1Address,
                          volatile UWORD8 * const CounterIrqRhea);


/*
-------------------------------------------------------------------------
 NAME        : RHEATST_AccessSizeMismatch										-
 DESCRIPTION : Program a right access                                   -
               to a peripheral with bad access size                     -
 PARAMETERS  :                                                          -
   AccesMismatchCounter: This counter is incremented for each raised    - 
	                      adress mismatch in the interrupt routine           
 RETURN VALUE: RES_OK on success otherwise RES_BAD  (refer Result.h)    -
 LIMITATIONS :  treatement in interrupt handler should be set
-------------------------------------------------------------------------
*/
UWORD16 RHEATST_AccessSizeMismatch (volatile UWORD8 * const CounterIrqRhea);



UWORD16 RHEATST_AbortGeneration(UWORD32 MissingPeripheralAddress);


UWORD16 RHEATST_CheckAbortRheaMisMatch(RHEA_Request_t     IsRequestType,
        				          RHEA_Access_Size_t IsMemoryAccessSize,
        				  			 RHEA_Access_Size_t IsPeripheralAccessSize,
						  			 UWORD32				  IsFaultAddress,
						  			 UWORD32				  IsData);
UWORD16  RHEATST_CheckAbortRheaTimeOut(RHEA_Request_t     IsRequestType,
        				         RHEA_Access_Size_t IsMemoryAccessSize,
						  			UWORD32				 IsFaultAddress,
						  			UWORD32				 IsData);


#endif


⌨️ 快捷键说明

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