Set up u-boot glue code and patching scripts.
[yaffs2.git] / direct / basic-test / yaffsnewcfg.c
index 60dcf022de6d682c0a242501ad46566896615c3a..06ae645655048bafb710224cdad8f5ade4642702 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * YAFFS: Yet Another Flash File System. A NAND-flash specific file system.
  *
- * Copyright (C) 2002-2010 Aleph One Ltd.
+ * Copyright (C) 2002-2011 Aleph One Ltd.
  *   for Toby Churchill Ltd and Brightstar Engineering
  *
  * Created by Charles Manning <charles@aleph1.co.uk>
@@ -37,61 +37,6 @@ unsigned yaffs_trace_mask =
        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
 
@@ -100,7 +45,7 @@ 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);