This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
How can hole node come into being? -- JFFS2
- From: =?gb2312?q?gu=20xm?= <guximei0322 at yahoo dot com dot cn>
- To: ecos-discuss at sources dot redhat dot com
- Cc: guximei0322 at yahoo dot com dot cn
- Date: Wed, 25 Dec 2002 12:12:22 +0800 (CST)
- Subject: [ECOS] How can hole node come into being? -- JFFS2
Hi all,
A problem has botherd me a long time. Anyone can
help me?
The whole jffs2 fs has hole node management as an
integrity part. But in write operation, it seemed that
the impossiblity to form a hole node has been
eliminated.
/*------------------------------------------*/
FILE <jffs2.c>
FUNC jffs2_fo_write
... ...
if( pos < 0 || pos > node->i_size )
return EINVAL;
... ...
FILE <file-ecos.c>
FUNC jffs2_prepare_write
... ...
if (pageofs > inode->i_size) {
// Here make a new hole node for cross a page
}
... ...
Also, after every write node operation, file offset
and inode i_size are advanced the real write length
without pad to PAGE.
/*------------------------------------------*/
Thanks in advance!
Guximei
_________________________________________________________
Do You Yahoo!?
"您想享受2-7折星级酒店价格吗?"
http://cn.travel.yahoo.com/
--
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss