diff options
author | Charles Manning <cdhmanning@gmail.com> | 2010-09-25 14:48:37 +1200 |
---|---|---|
committer | Charles Manning <cdhmanning@gmail.com> | 2010-09-25 14:48:37 +1200 |
commit | 55c18cfca44ed18e9501ddbde3a3361b4f377739 (patch) | |
tree | 61b122a4c1a94dbb8fe2c665db0d311780aa2279 /yaffs_allocator.c | |
parent | e96a9be41b7e129a2fbaf42bd72804e354a7447f (diff) |
yaffs Remove obsolete list debugging code
This code does not work any more so may as well delete it.
Signed-off-by: Charles Manning <cdhmanning@gmail.com>
Diffstat (limited to 'yaffs_allocator.c')
-rw-r--r-- | yaffs_allocator.c | 33 |
1 files changed, 0 insertions, 33 deletions
diff --git a/yaffs_allocator.c b/yaffs_allocator.c index 3807fc9..ab44bc7 100644 --- a/yaffs_allocator.c +++ b/yaffs_allocator.c @@ -168,21 +168,6 @@ static int yaffs_CreateTnodes(yaffs_Device *dev, int nTnodes) return YAFFS_FAIL; } - /* Hook them into the free list */ -#if 0 - for (i = 0; i < nTnodes - 1; i++) { - newTnodes[i].internal[0] = &newTnodes[i + 1]; -#ifdef CONFIG_YAFFS_TNODE_LIST_DEBUG - newTnodes[i].internal[YAFFS_NTNODES_INTERNAL] = (void *)1; -#endif - } - - newTnodes[nTnodes - 1].internal[0] = allocator->freeTnodes; -#ifdef CONFIG_YAFFS_TNODE_LIST_DEBUG - newTnodes[nTnodes - 1].internal[YAFFS_NTNODES_INTERNAL] = (void *)1; -#endif - allocator->freeTnodes = newTnodes; -#else /* New hookup for wide tnodes */ for (i = 0; i < nTnodes - 1; i++) { curr = (yaffs_Tnode *) &mem[i * dev->tnodeSize]; @@ -194,9 +179,6 @@ static int yaffs_CreateTnodes(yaffs_Device *dev, int nTnodes) curr->internal[0] = allocator->freeTnodes; allocator->freeTnodes = (yaffs_Tnode *)mem; -#endif - - allocator->nFreeTnodes += nTnodes; allocator->nTnodesCreated += nTnodes; @@ -239,13 +221,6 @@ yaffs_Tnode *yaffs_AllocateRawTnode(yaffs_Device *dev) if (allocator->freeTnodes) { tn = allocator->freeTnodes; -#ifdef CONFIG_YAFFS_TNODE_LIST_DEBUG - if (tn->internal[YAFFS_NTNODES_INTERNAL] != (void *)1) { - /* Hoosterman, this thing looks like it isn't in the list */ - T(YAFFS_TRACE_ALWAYS, - (TSTR("yaffs: Tnode list bug 1" TENDSTR))); - } -#endif allocator->freeTnodes = allocator->freeTnodes->internal[0]; allocator->nFreeTnodes--; } @@ -264,14 +239,6 @@ void yaffs_FreeRawTnode(yaffs_Device *dev, yaffs_Tnode *tn) } if (tn) { -#ifdef CONFIG_YAFFS_TNODE_LIST_DEBUG - if (tn->internal[YAFFS_NTNODES_INTERNAL] != 0) { - /* Hoosterman, this thing looks like it is already in the list */ - T(YAFFS_TRACE_ALWAYS, - (TSTR("yaffs: Tnode list bug 2" TENDSTR))); - } - tn->internal[YAFFS_NTNODES_INTERNAL] = (void *)1; -#endif tn->internal[0] = allocator->freeTnodes; allocator->freeTnodes = tn; allocator->nFreeTnodes++; |