*** empty log message ***
[yaffs/.git] / yaffs_fileem.c
index dd77b37fca0fd0ab946a6b241c2ff5abce38b1af..b850581d9b1e3da6ddee81f6fb87bf522a240786 100644 (file)
@@ -56,6 +56,16 @@ static int IsAMarkedBadBlock(int blk)
 
 static __u8 yaffs_WriteFailCorruption(int chunkInNAND)
 {
+
+       // Whole blocks that fail
+       switch(chunkInNAND/YAFFS_CHUNKS_PER_BLOCK)
+       {
+               case 50:
+               case 52:
+                                       return 7;
+       }
+       
+       // Single blocks that fail
        switch(chunkInNAND)
        {
                case 2000:
@@ -70,9 +80,10 @@ static __u8 yaffs_WriteFailCorruption(int chunkInNAND)
                case 3006:
                case 3007:  return 1;// ding one bit
                
-               default: return 0;
                
        }
+
+       return 0;
 }
 
 static void yaffs_ModifyWriteData(int chunkInNAND,__u8 *data)