[Yaffs] About nDeletedFiles and nUnlinkedFiles

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: Oğuzhan Zilci
Date:  
To: yaffs@lists.aleph1.co.uk
Subject: [Yaffs] About nDeletedFiles and nUnlinkedFiles
Dear All,

I'm a very new to YAFFS2 and had little experience on flash file systems. We are using YAFFS2 on a 512 MB NAND Chip on an embedded uclinux system. After some read/write/delete etc operations on flash, nDeletedFiles and nUnlinkedFiles (obtained from /proc/yaffs) becomes about 30k-40k and memory footprint of yaffs becomes about 5MB. I test this by running "free" command before and after mounting yaffs2.
Are we doing something wrong, is this an expected value? We are running low on system memory and need ever bit of it, can we do some periodic operation (on user space is preferred rather then kernel) to check and clean up nDeletedFiles. I guess since about 5% to 10% of the flash is used in or system, garbage collection mechanism is not started (may be not necessary?), but we need something like that. Creating a huge file on flash (about the size of it) then deleting it increases free memory again. Any comment, suggestion, method, idea is welcomed.

Thanks in advance,
Best Regards,
OZ