www.pudn.com > drivers.rar
To Read all the content
[file head]:
/******************************************************************************
* Flash File System (ffs)
* Idea, design and coding by Mads Meisner-Jensen, mmj@ti.com
*
* ffs test cases
*
* $Id: tcases.c 1.13.1.1.1.66 Thu, 08 Jan 2004 15:05:23 +0100 tsj $
*
******************************************************************************/
#ifndef TARGET
#include "ffs.cfg"
#endif
#include "ffs/ffs_api.h" // Temp
#include "ffs/ffs.h"
#include "ffs/board/tffs.h"
#include "ffs/board/core.h" // only for block/object recovery test flags
#include "ffs/board/tdata.h"
#include "ffs/board/ffstrace.h"
#include "ffs/board/drv.h"
#include "ffs/pcm.h"
#if((TARGET == 1) || (RIV_ENV==1))
#include "rvf/rvf_api.h" // this include rv_general.h and rvf_target.h
#include "rvm/rvm_use_id_list.h"
#endif
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <limits.h>
#include <assert.h>
#include <stddef.h>
#if (TARGET == 0)
#include <setjmp.h>
... ...
[file tail]:
... ...
dbrec", PC, case_data_brecover, "Test data block recovery" },
// Powerfail tests (don't use powerfail framework).
{ "pfblkh", PC, case_blkheader_powerfail,"Test blockheader for pf " },
{ "pfob", PC, case_obj_powerfail, "Test create of objects for pf" },
// Helper test case
{ "tr", PC|IT, case_trace_mask, "Change trace mask on the fly " },
{ "dh", PC|IT, case_debug_help, "Difference help functions " },
{ 0, 0, 0, 0 }
};
#if (TARGET == 1)
// Note like the interrupt functions in drv.c this asm needs to be places ad
// the buttom of the file or else it crach!
uint32 get_cpsr(void)
{
asm(" .state16");
asm(" adr A2, get_cpsr32");
asm(" bx A2");
asm(" .state32");
asm("get_cpsr32");
asm(" mrs A1,cpsr ; get current CPSR");
}
#else
uint32 get_cpsr(void){return 0;}
#endif