From wikim@ebcard.co.kr Mon Dec 28 05:22:04 2009
Received: from smtpoutbound2.entumoffice.com ([211.218.127.49])
	by stoneboat.aleph1.co.uk with esmtp (Exim 4.69)
	(envelope-from <wikim@ebcard.co.kr>) id 1NP83K-0000PS-07
	for yaffs@lists.aleph1.co.uk; Mon, 28 Dec 2009 05:22:04 +0000
Received: from smtpinbound01.entumoffice.com ([211.218.127.46]) by
	smtpoutbound2.entumoffice.com with Microsoft SMTPSVC(6.0.3790.3959); 
	Mon, 28 Dec 2009 14:21:16 +0900
Received: from spamgw.bizmeka.com ([211.218.127.39]) by
	smtpinbound01.entumoffice.com with Microsoft SMTPSVC(6.0.3790.3959); 
	Mon, 28 Dec 2009 14:21:15 +0900
Received: from unknown (HELO kwiPC)
	(wikim@ebcard.co.krzmeka.com@211.175.117.254)
	by 211.218.127.39 with ESMTP; 28 Dec 2009 14:21:38 +0900
X-Original-SENDERIP: 211.175.117.254
X-Original-MAILFROM: wikim@ebcard.co.kr
Message-ID: <722809E224F741168128F6F02A0A41CA@kwiPC>
From: "???" <wikim@ebcard.co.kr>
To: "Charles Manning" <cdhmanning@gmail.com>,
 <yaffs@lists.aleph1.co.uk>
References: <200911301632.27711.manningc2@actrix.gen.nz><200912241403.49493.manningc2@actrix.gen.nz><2df346410912231745m28f32f29ub49e15dd70061b27@mail.gmail.com><200912241730.27786.manningc2@actrix.gen.nz><2df346410912232154le2a6a0ftf670670ead7c7e2@mail.gmail.com>
	<2e228380912241812y174a0b9chacb400411a15ad2f@mail.gmail.com>
In-Reply-To: <2e228380912241812y174a0b9chacb400411a15ad2f@mail.gmail.com>
Date: Mon, 28 Dec 2009 14:21:44 +0900
MIME-Version: 1.0
Content-Type: multipart/alternative;
	boundary="----=_NextPart_000_0018_01CA87C9.15289D80"
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: Microsoft Windows Mail 6.0.6001.18000
X-MimeOLE: Produced By Microsoft MimeOLE V6.0.6001.18049
X-OriginalArrivalTime: 28 Dec 2009 05:21:15.0762 (UTC)
	FILETIME=[9406DD20:01CA877D]
X-SA-Exim-Connect-IP: 211.218.127.49
X-SA-Exim-Mail-From: wikim@ebcard.co.kr
X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on
	stoneboat.aleph1.co.uk
X-Spam-Level: *
X-Spam-Status: No, score=2.0 required=4.5 tests=AWL,BAYES_50,HTML_MESSAGE,
	RCVD_IN_SORBS_WEB autolearn=no version=3.2.5
X-SA-Exim-Version: 4.2.1 (built Wed, 25 Jun 2008 17:14:11 +0000)
X-SA-Exim-Scanned: Yes (on stoneboat.aleph1.co.uk)
Subject: [Yaffs] partiall writen block... why occur?
X-BeenThere: yaffs@lists.aleph1.co.uk
X-Mailman-Version: 2.1.11
Precedence: list
List-Id: Discussion of YAFFS NAND flash filesystem <yaffs.lists.aleph1.co.uk>
List-Unsubscribe: <http://lists.aleph1.co.uk/cgi-bin/mailman/options/yaffs>,
	<mailto:yaffs-request@lists.aleph1.co.uk?subject=unsubscribe>
List-Archive: <http://lists.aleph1.co.uk/lurker/list/yaffs.html>
List-Post: <mailto:yaffs@lists.aleph1.co.uk>
List-Help: <mailto:yaffs-request@lists.aleph1.co.uk?subject=help>
List-Subscribe: <http://lists.aleph1.co.uk/cgi-bin/mailman/listinfo/yaffs>,
	<mailto:yaffs-request@lists.aleph1.co.uk?subject=subscribe>
X-List-Received-Date: Mon, 28 Dec 2009 05:22:04 -0000

This is a multi-part message in MIME format.

------=_NextPart_000_0018_01CA87C9.15289D80
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

hello... sir

why occur "Partially written block %d detected" ?


thank you...=20

I wish ..... as soon as .... let 's send e-mail to me.



1. yaffs filesystem version Info
const char *yaffs_guts_c_version =3D
    "$Id: yaffs_guts.c,v 1.95 2009/11/11 01:40:41 charles Exp $";


2. occur point...

static int yaffs_ScanBackwards(yaffs_Device *dev) in yaffs_guts.c



if (foundChunksInBlock) {
     /* This is a chunk that was skipped due to failing the erased check =
*/
    } else if (c =3D=3D 0) {
     /* We're looking at the first chunk in the block so the block is =
unused */
     state =3D YAFFS_BLOCK_STATE_EMPTY;
     dev->nErasedBlocks++;
    } else {
     if (state =3D=3D YAFFS_BLOCK_STATE_NEEDS_SCANNING ||
         state =3D=3D YAFFS_BLOCK_STATE_ALLOCATING) {
      if (dev->sequenceNumber =3D=3D bi->sequenceNumber) {
       /* this is the block being allocated from */

       T(YAFFS_TRACE_SCAN,
         (TSTR
          (" Allocating from %d %d"
           TENDSTR), blk, c));

       state =3D YAFFS_BLOCK_STATE_ALLOCATING;
       dev->allocationBlock =3D blk;
       dev->allocationPage =3D c;
       dev->allocationBlockFinder =3D blk;
      } else {
       /* This is a partially written block that is not
        * the current allocation block. This block must have
        * had a write failure, so set up for retirement.
        */

        /* bi->needsRetiring =3D 1; ??? TODO */
        bi->gcPrioritise =3D 1;

        T(YAFFS_TRACE_ALWAYS,
        (TSTR("Partially written block %d detected" TENDSTR),            =
        <<--------- why occur ?
        blk));
      }
     }
    }

3. you will know the reason that "Partially written block xx detected".
    what do occur the reason? and what is slove method?
 
------=_NextPart_000_0018_01CA87C9.15289D80
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.6001.18099" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY>
<DIV><FONT size=3D2>hello... sir</FONT></DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2>why <FONT color=3D#ff0000>occur "Partially written =
block %d=20
detected" ?</FONT></FONT></DIV>
<DIV><FONT color=3D#ff0000 size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT color=3D#ff0000 size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2>thank you... </FONT></DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2>I wish ..... as soon as .... let 's send e-mail to=20
me.</FONT></DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT color=3D#ff0000 size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT color=3D#ff0000 size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2><STRONG>1. yaffs filesystem version =
Info</STRONG></FONT></DIV>
<DIV><FONT size=3D2>const char *yaffs_guts_c_version =
=3D<BR>&nbsp;&nbsp;&nbsp; "$Id:=20
yaffs_guts.c,v 1.95 2009/11/11 01:40:41 charles Exp $";</FONT></DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2><STRONG>2. occur point...</STRONG></FONT></DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2>static int yaffs_ScanBackwards(yaffs_Device *dev) in =

yaffs_guts.c</FONT></DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2>if (foundChunksInBlock) =
{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/*=20
This is a chunk that was skipped due to failing the erased check=20
*/<BR>&nbsp;&nbsp;&nbsp;&nbsp;} else if (c =3D=3D 0)=20
{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/* We're looking at the first chunk =
in the=20
block so the block is unused */<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;state =
=3D=20
YAFFS_BLOCK_STATE_EMPTY;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;dev-&gt;nErased=
Blocks++;<BR>&nbsp;&nbsp;&nbsp;&nbsp;}=20
else {<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if (state =3D=3D=20
YAFFS_BLOCK_STATE_NEEDS_SCANNING=20
||<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; state =3D=3D=20
YAFFS_BLOCK_STATE_ALLOCATING) =
{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if=20
(dev-&gt;sequenceNumber =3D=3D bi-&gt;sequenceNumber)=20
{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/* this is the block =
being=20
allocated from */</FONT></DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT=20
size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;T(YAFFS_TRACE_SCAN,<BR=
>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
(TSTR<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (" =
Allocating=20
from %d =
%d"<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
TENDSTR), blk, c));</FONT></DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;state =3D=20
YAFFS_BLOCK_STATE_ALLOCATING;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p;dev-&gt;allocationBlock=20
=3D =
blk;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;dev-&gt;allocationPage =
=3D=20
c;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;dev-&gt;allocationBlockFi=
nder =3D=20
blk;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;} else=20
{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/* This is a partially =
written=20
block that is not<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * the =
current=20
allocation block. This block must=20
have<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * had a write =
failure, so set=20
up for retirement.<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
*/</FONT></DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /*=20
bi-&gt;needsRetiring =3D 1; ??? TODO=20
*/<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; bi-&gt;gcPrioritise =3D =

1;</FONT></DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT=20
size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<STRONG>&nbsp;</STRONG><FONT=
=20
color=3D#ff0000><STRONG>=20
T(YAFFS_TRACE_ALWAYS,<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
(TSTR("Partially written block %d detected" TENDSTR),&nbsp;&nbsp;&nbsp;=20
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; =
&nbsp;&nbsp;&nbsp;=20
&lt;&lt;--------- why occur =
?<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
blk));<BR></STRONG></FONT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<BR>&nbsp;=
&nbsp;&nbsp;&nbsp;&nbsp;}<BR>&nbsp;&nbsp;&nbsp;&nbsp;}</FONT></DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2>3. you will know the reason that "Partially written =
block xx=20
detected".</FONT></DIV>
<DIV><FONT size=3D2>&nbsp;&nbsp;&nbsp; what do occur the reason? and =
what is slove=20
method?</FONT></DIV>
<DIV><FONT size=3D2>&nbsp;</FONT></DIV></BODY></HTML>

------=_NextPart_000_0018_01CA87C9.15289D80--



