Hi All,
Kindly do know you comments and feedback on this patch.
With Regards
Gangheyamoorthy.A.P
-----Original Message-----
From: apgmoorthy [
mailto:moorthy.apg@samsung.com]
Sent: Monday, September 22, 2008 8:53 PM
To: '
yaffs@lists.aleph1.co.uk'
Cc: '
manningc2@actrix.gen.nz'
Subject: [PATCH] [YAFFS2] Skip spare area read when using wide Tnodes
During read operation, there is an additional spare read while
determining flash page address for a file offest in
yaffs_FindChunkInGroup. This spare read is useful only when
"Disable Wide Tnodes" option is enabled.
In this patch, we check if groupSize is 1 ie if individual flash
page addresses are stored in level 0 Tnodes. If so, then we skip
the spare read check for that chunk and return that the requested
chunk is found to be correct.
Signed-off-by: Rohit Hagargundgi <h.rohit@samsung.com>
--- a/fs/yaffs2/yaffs_guts.c 2008-09-02 17:50:02.000000000 +0530
+++ b/fs/yaffs2/yaffs_guts.c 2008-09-02 17:48:57.000000000 +0530
@@ -1551,6 +1551,9 @@ static int yaffs_FindChunkInGroup(yaffs_
{
int j;
+ if (dev->chunkGroupSize == 1)
+ return theChunk ? theChunk : -1;
+
for (j = 0; theChunk && j < dev->chunkGroupSize; j++) {
if (yaffs_CheckChunkBit
(dev, theChunk / dev->nChunksPerBlock,