projects
/
yaffs2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix sign handling problem. This works, buut should probably be improved
[yaffs2.git]
/
yaffs_mtdif2.c
diff --git
a/yaffs_mtdif2.c
b/yaffs_mtdif2.c
index 0b3c921ada0ae99ca9a56883dea4b5d3897a1f0f..6ed89c24a3f20f9284918f50143e11a21719cad9 100644
(file)
--- a/
yaffs_mtdif2.c
+++ b/
yaffs_mtdif2.c
@@
-14,7
+14,7
@@
/* mtd interface for YAFFS2 */
const char *yaffs_mtdif2_c_version =
/* mtd interface for YAFFS2 */
const char *yaffs_mtdif2_c_version =
- "$Id: yaffs_mtdif2.c,v 1.2
1 2008-07-23 03:35:12
charles Exp $";
+ "$Id: yaffs_mtdif2.c,v 1.2
2 2008-11-02 22:47:13
charles Exp $";
#include "yportenv.h"
#include "yportenv.h"
@@
-107,7
+107,7
@@
int nandmtd2_ReadChunkWithTagsFromNAND(yaffs_Device * dev, int chunkInNAND,
int retval = 0;
int localData = 0;
int retval = 0;
int localData = 0;
- loff_t addr = ((loff_t) chunkInNAND) * dev->
nData
BytesPerChunk;
+ loff_t addr = ((loff_t) chunkInNAND) * dev->
total
BytesPerChunk;
yaffs_PackedTags2 pt;
yaffs_PackedTags2 pt;
@@
-194,7
+194,7
@@
int nandmtd2_MarkNANDBlockBad(struct yaffs_DeviceStruct *dev, int blockNo)
retval =
mtd->block_markbad(mtd,
blockNo * dev->nChunksPerBlock *
retval =
mtd->block_markbad(mtd,
blockNo * dev->nChunksPerBlock *
- dev->
nData
BytesPerChunk);
+ dev->
total
BytesPerChunk);
if (retval == 0)
return YAFFS_OK;
if (retval == 0)
return YAFFS_OK;
@@
-214,7
+214,7
@@
int nandmtd2_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
retval =
mtd->block_isbad(mtd,
blockNo * dev->nChunksPerBlock *
retval =
mtd->block_isbad(mtd,
blockNo * dev->nChunksPerBlock *
- dev->
nData
BytesPerChunk);
+ dev->
total
BytesPerChunk);
if (retval) {
T(YAFFS_TRACE_MTD, (TSTR("block is bad" TENDSTR)));
if (retval) {
T(YAFFS_TRACE_MTD, (TSTR("block is bad" TENDSTR)));