summaryrefslogtreecommitdiffstats
path: root/target/linux/generic/files/fs/yaffs2/yaffs_packedtags1.c
diff options
context:
space:
mode:
authorjuhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>2012-10-30 14:58:17 +0000
committerjuhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>2012-10-30 14:58:17 +0000
commit34b60fad1a368d4fd65605475334a9e52f43f7bc (patch)
tree825ff262860bdf4939b271f13d9b72542af61501 /target/linux/generic/files/fs/yaffs2/yaffs_packedtags1.c
parent22c66493c9726e1109cb51a6063e76ff4876ba38 (diff)
generic: fold yaffs_git_2010_10_20 patch to generic/files
Signed-off-by: Gabor Juhos <juhosg@openwrt.org> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@34013 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/generic/files/fs/yaffs2/yaffs_packedtags1.c')
-rw-r--r--target/linux/generic/files/fs/yaffs2/yaffs_packedtags1.c36
1 files changed, 18 insertions, 18 deletions
diff --git a/target/linux/generic/files/fs/yaffs2/yaffs_packedtags1.c b/target/linux/generic/files/fs/yaffs2/yaffs_packedtags1.c
index 3e67e6916..3ad49a941 100644
--- a/target/linux/generic/files/fs/yaffs2/yaffs_packedtags1.c
+++ b/target/linux/generic/files/fs/yaffs2/yaffs_packedtags1.c
@@ -1,7 +1,7 @@
/*
* YAFFS: Yet Another Flash File System. A NAND-flash specific file system.
*
- * Copyright (C) 2002-2007 Aleph One Ltd.
+ * Copyright (C) 2002-2010 Aleph One Ltd.
* for Toby Churchill Ltd and Brightstar Engineering
*
* Created by Charles Manning <charles@aleph1.co.uk>
@@ -14,37 +14,37 @@
#include "yaffs_packedtags1.h"
#include "yportenv.h"
-void yaffs_PackTags1(yaffs_PackedTags1 *pt, const yaffs_ExtendedTags *t)
+void yaffs_PackTags1(yaffs_PackedTags1 *pt, const yaffs_ext_tags *t)
{
- pt->chunkId = t->chunkId;
- pt->serialNumber = t->serialNumber;
- pt->byteCount = t->byteCount;
- pt->objectId = t->objectId;
+ pt->chunk_id = t->chunk_id;
+ pt->serial_number = t->serial_number;
+ pt->n_bytes = t->n_bytes;
+ pt->obj_id = t->obj_id;
pt->ecc = 0;
- pt->deleted = (t->chunkDeleted) ? 0 : 1;
+ pt->deleted = (t->is_deleted) ? 0 : 1;
pt->unusedStuff = 0;
pt->shouldBeFF = 0xFFFFFFFF;
}
-void yaffs_UnpackTags1(yaffs_ExtendedTags *t, const yaffs_PackedTags1 *pt)
+void yaffs_unpack_tags1(yaffs_ext_tags *t, const yaffs_PackedTags1 *pt)
{
static const __u8 allFF[] =
{ 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff };
if (memcmp(allFF, pt, sizeof(yaffs_PackedTags1))) {
- t->blockBad = 0;
+ t->block_bad = 0;
if (pt->shouldBeFF != 0xFFFFFFFF)
- t->blockBad = 1;
- t->chunkUsed = 1;
- t->objectId = pt->objectId;
- t->chunkId = pt->chunkId;
- t->byteCount = pt->byteCount;
- t->eccResult = YAFFS_ECC_RESULT_NO_ERROR;
- t->chunkDeleted = (pt->deleted) ? 0 : 1;
- t->serialNumber = pt->serialNumber;
+ t->block_bad = 1;
+ t->chunk_used = 1;
+ t->obj_id = pt->obj_id;
+ t->chunk_id = pt->chunk_id;
+ t->n_bytes = pt->n_bytes;
+ t->ecc_result = YAFFS_ECC_RESULT_NO_ERROR;
+ t->is_deleted = (pt->deleted) ? 0 : 1;
+ t->serial_number = pt->serial_number;
} else {
- memset(t, 0, sizeof(yaffs_ExtendedTags));
+ memset(t, 0, sizeof(yaffs_ext_tags));
}
}