X-Git-Url: http://aleph1.co.uk/gitweb/?a=blobdiff_plain;f=yaffs_guts.c;h=ebe7e772ea7a86a2177c4be11604d449db8a11b8;hb=refs%2Fheads%2Faleph1-release-branch;hp=5db3da643403b6b9a9ad2aa4452ef1089cc73495;hpb=9b9fd2ac90990fed4990feec36ab1ec55fc78926;p=yaffs2.git diff --git a/yaffs_guts.c b/yaffs_guts.c index 5db3da6..ebe7e77 100644 --- a/yaffs_guts.c +++ b/yaffs_guts.c @@ -10,6 +10,7 @@ * it under the terms of the GNU General Public License version 2 as * published by the Free Software Foundation. */ + #include "yportenv.h" #include "yaffs_trace.h" @@ -431,9 +432,9 @@ static int yaffs_WriteNewChunkWithTagsToNAND(struct yaffs_DeviceStruct *dev, /* let's give it a try */ attempts++; -#ifdef CONFIG_YAFFS_ALWAYS_CHECK_CHUNK_ERASED - bi->skipErasedCheck = 0; -#endif + if(dev->param.alwaysCheckErased) + bi->skipErasedCheck = 0; + if (!bi->skipErasedCheck) { erasedOk = yaffs_CheckChunkErased(dev, chunk); if (erasedOk != YAFFS_OK) { @@ -5535,9 +5536,8 @@ static int yaffs_CheckStructures(void) /* yaffs_CheckStruct(yaffs_Tags,8,"yaffs_Tags"); */ /* yaffs_CheckStruct(yaffs_TagsUnion,8,"yaffs_TagsUnion"); */ /* yaffs_CheckStruct(yaffs_Spare,16,"yaffs_Spare"); */ -#ifndef CONFIG_YAFFS_TNODE_LIST_DEBUG /* yaffs_CheckStruct(yaffs_Tnode, 2 * YAFFS_NTNODES_LEVEL0, "yaffs_Tnode"); */ -#endif + #ifndef CONFIG_YAFFS_WINCE yaffs_CheckStruct(yaffs_ObjectHeader, 512, "yaffs_ObjectHeader"); #endif