Revert "yaffs: Update stats when using mtdif2."
author黄涛 <huangtao@rock-chips.com>
Sat, 30 Jul 2011 14:45:15 +0000 (22:45 +0800)
committer黄涛 <huangtao@rock-chips.com>
Sat, 30 Jul 2011 14:45:15 +0000 (22:45 +0800)
This reverts commit a660ce8105791a9ef6b4cf4836cac073c8736442.

fs/yaffs2/yaffs_mtdif2.c

index bd8128c06f053320212872850863cf9fd9ce7abb..fcb50992cdebda0904ef5aba1bb8760b25352555 100644 (file)
@@ -52,7 +52,6 @@ int nandmtd2_WriteChunkWithTagsToNAND(yaffs_Device *dev, int chunkInNAND,
           ("nandmtd2_WriteChunkWithTagsToNAND chunk %d data %p tags %p"
            TENDSTR), chunkInNAND, data, tags));
 
-       dev->nPageWrites++;
 
        addr  = ((loff_t) chunkInNAND) * dev->totalBytesPerChunk;
 
@@ -116,8 +115,6 @@ int nandmtd2_ReadChunkWithTagsFromNAND(yaffs_Device *dev, int chunkInNAND,
           ("nandmtd2_ReadChunkWithTagsFromNAND chunk %d data %p tags %p"
            TENDSTR), chunkInNAND, data, tags));
 
-       dev->nPageReads++;
-
        if (dev->inbandTags) {
 
                if (!data) {
@@ -177,14 +174,10 @@ int nandmtd2_ReadChunkWithTagsFromNAND(yaffs_Device *dev, int chunkInNAND,
        if (localData)
                yaffs_ReleaseTempBuffer(dev, data, __LINE__);
 
-       if (tags && retval == -EBADMSG && tags->eccResult == YAFFS_ECC_RESULT_NO_ERROR) {
+       if (tags && retval == -EBADMSG && tags->eccResult == YAFFS_ECC_RESULT_NO_ERROR)
                tags->eccResult = YAFFS_ECC_RESULT_UNFIXED;
-               dev->eccUnfixed++;
-       }
-       if (tags && retval == -EUCLEAN && tags->eccResult == YAFFS_ECC_RESULT_NO_ERROR) {
+       if (tags && retval == -EUCLEAN && tags->eccResult == YAFFS_ECC_RESULT_NO_ERROR)
                tags->eccResult = YAFFS_ECC_RESULT_FIXED;
-               dev->eccFixed++;
-       }
        if (retval == 0)
                return YAFFS_OK;
        else