public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
* Endless garbage collection
@ 2001-01-23 15:59 Simon Munton
  2001-01-23 16:06 ` David Woodhouse
  2001-01-23 16:20 ` Martin Gadbois
  0 siblings, 2 replies; 3+ messages in thread
From: Simon Munton @ 2001-01-23 15:59 UTC (permalink / raw)
  To: JFFS (E-mail), MTD (E-mail)

Hi,

It's possible to get the garbage collection going in an endless loop by
creating lots of small files. eg, if I create 25 files, each 0 bytes long,
on an empty filesystem, garbage collection starts and goes on and on.

Perhaps the test for too much RAM being used in thread_should_wake() ought
to take the number of files into account? ie should it be:

	/* If there is too much RAM used by the various structures, GC */
	if (jffs_get_node_inuse() >
(c->fmc->used_size/c->fmc->max_chunk_size * 5 + 25 + jffs_get_file_count()))
{

where  jffs_get_file_count() returns the number of files on the filesystem.

Simon



To unsubscribe, send "unsubscribe mtd" to majordomo@infradead.org

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2001-01-23 16:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-01-23 15:59 Endless garbage collection Simon Munton
2001-01-23 16:06 ` David Woodhouse
2001-01-23 16:20 ` Martin Gadbois

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox