yaffs Added some more tests to timothy_tests.
[yaffs2.git] / direct / basic-test / yaffsnewcfg.c
index fa993421caa4f8529c5f5d811b0092bab4f01193..5add1e686dd9c249e83a524a4f01628520dbcfe7 100644 (file)
@@ -23,7 +23,7 @@
 #include "yaffs_trace.h"
 #include "yramsim.h"
 
-unsigned yaffs_traceMask = 
+unsigned yaffs_trace_mask = 
 
        YAFFS_TRACE_SCAN |  
        YAFFS_TRACE_GC |
@@ -37,70 +37,15 @@ unsigned yaffs_traceMask =
        0;
         
 
-static int yaffsfs_lastError;
-
-void yaffsfs_SetError(int err)
-{
-       //Do whatever to set error
-       yaffsfs_lastError = err;
-}
-
-
-int yaffsfs_GetLastError(void)
-{
-       return yaffsfs_lastError;
-}
-
-void yaffsfs_Lock(void)
-{
-}
-
-void yaffsfs_Unlock(void)
-{
-}
-
-__u32 yaffsfs_CurrentTime(void)
-{
-       return 0;
-}
-
-
-static int yaffs_kill_alloc = 0;
-static size_t total_malloced = 0;
-static size_t malloc_limit = 0 & 6000000;
-
-void *yaffs_malloc(size_t size)
-{
-       void * this;
-       if(yaffs_kill_alloc)
-               return NULL;
-       if(malloc_limit && malloc_limit <(total_malloced + size) )
-               return NULL;
-
-       this = malloc(size);
-       if(this)
-               total_malloced += size;
-       return this;
-}
-
-void yaffs_free(void *ptr)
-{
-       free(ptr);
-}
-
-void yaffsfs_LocalInitialisation(void)
-{
-       // Define locking semaphore.
-}
 
 // Configuration
 
 
-int yaffs_StartUp(void)
+int yaffs_start_up(void)
 {
        // Stuff to configure YAFFS
        // Stuff to initialise anything special (eg lock semaphore).
-       yaffsfs_LocalInitialisation();
+       yaffsfs_OSInitialisation();
        yramsim_CreateRamSim("yaffs2",1,1000,0,0);
        yramsim_CreateRamSim("p0",0,0x400,1,0xff);
        yramsim_CreateRamSim("p1",0,0x400,1,0);