#include "yaffs_guts.h" /* Only for dumping device innards */
-extern int yaffs_traceMask;
+extern int yaffs_trace_mask;
void dumpDir(const char *dname);
{
char fn[100];
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(path);
{
char fn[100];
int h;
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(path);
int h;
int i;
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(path);
sprintf(fn,"%s/%s",path,"f1");
- yaffs_StartUp();
+ yaffs_start_up();
for(i = 0; i < niterations; i++)
{
printf("\n*****************\nIteration %d\n",i);
sprintf(fn[1],"%s/%s",path,"f1");
sprintf(fn[2],"%s/%s",path,"f2");
- yaffs_StartUp();
+ yaffs_start_up();
for(i = 0; i < niterations; i++)
{
mode_t temp_mode;
struct yaffs_stat ystat;
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount("/boot");
yaffs_mount("/data");
yaffs_unlink("/boot/zlf");
- yaffs_DumpDevStruct("/boot");
+ yaffs_dump_dev("/boot");
fill_disk_and_delete("/boot",20,20);
- yaffs_DumpDevStruct("/boot");
+ yaffs_dump_dev("/boot");
fill_files("/boot",1,10000,0);
fill_files("/boot",1,10000,5000);
leave_unlinked_file("/data",20000,5000);
leave_unlinked_file("/data",20000,5000);
- yaffs_DumpDevStruct("/boot");
- yaffs_DumpDevStruct("/data");
+ yaffs_dump_dev("/boot");
+ yaffs_dump_dev("/data");
char str[100];
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(path);
sprintf(b,"%s/b",mountpt);
sprintf(c,"%s/c",mountpt);
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
char abuffer[1000];
char bbuffer[1000];
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(path);
int j;
int a;
int b;
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(path);
{
struct yaffs_stat s;
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(path);
char bbuffer[1000];
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(path);
char abuffer[1000];
char bbuffer[1000];
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(path);
int directory_rename_test(void)
{
int r;
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount("/ram");
yaffs_mkdir("/ram/a",0);
int sizeOfFiles = 500000;
char buffer[100];
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount("/boot");
memset(buffer1,0,sizeof(buffer1));
memset(buffer2,0,sizeof(buffer2));
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount("/boot");
{
int f;
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount("/boot");
fill_disk("/boot/",2);
f = yaffs_freespace("/boot");
char y[10];
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount("/boot");
yaffs_unlink("/boot/trunctest");
void fill_disk_test(const char *mountpt)
{
int i;
- yaffs_StartUp();
+ yaffs_start_up();
for(i = 0; i < 5; i++)
{
void fill_files_test(const char *mountpt)
{
int i;
- yaffs_StartUp();
+ yaffs_start_up();
for(i = 0; i < 5; i++)
{
void fill_empty_files_test(const char *mountpt)
{
int i;
- yaffs_StartUp();
+ yaffs_start_up();
char name[100];
int result = 0;
void long_name_test(const char *mountpt)
{
int i;
- yaffs_StartUp();
+ yaffs_start_up();
char fullName[1000];
char name[300];
int result = 0;
yaffs_DIR *d;
yaffs_dirent *de;
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
int result = 0;
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
sprintf(b,"%s/bbb",mountpt);
sprintf(c,"%s/ccc",mountpt);
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
sprintf(a,"%s/aaa",mountpt);
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
int f3;
sprintf(a,"%s/aaa",mountpt);
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
sprintf(a,"%s/aaa",mountpt);
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
int h;
sprintf(sub,"%s/sdir",mountpt);
- yaffs_StartUp();
+ yaffs_start_up();
for(j = 0; j < 10; j++)
{
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
yaffs_unlink(a);
yaffs_unlink(b);
sprintf(a,"%s/a",mountpt);
- yaffs_StartUp();
+ yaffs_start_up();
for(i = 0; i < nmounts; i++){
int h0;
sprintf(a,"%s/a",mountpt);
- yaffs_StartUp();
+ yaffs_start_up();
sprintf(a,"%s/a",mountpt);
- yaffs_StartUp();
+ yaffs_start_up();
sprintf(a,"%s/f",mountpt);
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
- yaffs_StartUp();
+ yaffs_start_up();
for(i = 0; i < nmounts; i++){
printf("############### Iteration %d Start\n",i);
printf("Create start condition\n");
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
yaffs_mkdir(a,0);
sprintf(b,"%s/zz",a);
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
int r;
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
void rmdir_test(const char *mountpt)
{
char name[100];
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
int result;
int val1;
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
int result;
char val[1000];
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);
}
-void dump_dev_stats(yaffs_Device *dev, const char * str)
+void dump_dev_stats(yaffs_dev_t *dev, const char * str)
{
printf("%s\n",str);
printf( "space free %d erased %d "
"nand reads %d writes %d erases %d "
"gc all %d passive %d oldestdirty %d blocks %d copies %d \n",
- dev->nFreeChunks, dev->nErasedBlocks * dev->param.nChunksPerBlock,
- dev->nPageReads, dev->nPageWrites, dev->nBlockErasures,
- dev->allGCs, dev->passiveGCs, dev->oldestDirtyGCs, dev->nGCBlocks, dev->nGCCopies);
+ dev->n_free_chunks, dev->n_erased_blocks * dev->param.chunks_per_block,
+ dev->n_page_reads, dev->n_page_writes, dev->n_erasures,
+ dev->all_gcs, dev->passive_gc_count, dev->oldest_dirty_gc_count, dev->n_gc_blocks, dev->n_gc_copies);
}
void test_flash_traffic(const char *mountpt)
char name0[100];
char name1[100];
int i;
- yaffs_Device *dev;
+ yaffs_dev_t *dev;
- yaffs_traceMask = 0;
+ yaffs_trace_mask = 0;
- yaffs_StartUp();
+ yaffs_start_up();
yaffs_mount(mountpt);