diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-03-09 10:34:55 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-03-09 10:34:55 -0800 |
commit | 6e96783f586cc0a64651087cb518209a8577123f (patch) | |
tree | 8b74a5a8fda055ffeaa0c1ae3c070772599f8b3b /fs/jffs2/background.c | |
parent | 8466c833799b30ab343c5108cd2e460f9f16c9d8 (diff) | |
parent | 0feba829ee82a6e43baabe3f0bdf91bd937a67a1 (diff) | |
download | op-kernel-dev-6e96783f586cc0a64651087cb518209a8577123f.zip op-kernel-dev-6e96783f586cc0a64651087cb518209a8577123f.tar.gz |
Merge git://git.infradead.org/mtd-2.6
* git://git.infradead.org/mtd-2.6:
[JFFS2] print a message when marking bad block
[JFFS2] Check for all-zero node headers
[MTD] [OneNAND] Classify the page data and oob buffer
[MTD] [OneNAND] Exit the loop when transferring/filling of the oob is finished
[MTD] [OneNAND] add Nokia Copyright and a credit
[MTD] [OneNAND] Fix typo & wrong comments
[MTD] [OneNAND] Use oob buffer instead of main one in oob functions
[MTD] Correct partition failed erase address
[JFFS2] Use yield() between GC passes in background thread.
[MTD] [NAND] Correct misspelled preprocessor variable.
[MTD] [MAPS] dilnetpc: Fix printk warning
[MTD] [NOR] Fix oops in cfi_amdstd_sync
[MTD] ESB2 check for closed ROM window
[JFFS2] Fix writebuffer recovery in the first page of a block
[MTD] [NAND] make oobavail public
Diffstat (limited to 'fs/jffs2/background.c')
-rw-r--r-- | fs/jffs2/background.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/fs/jffs2/background.c b/fs/jffs2/background.c index 6eb3dae..888f236 100644 --- a/fs/jffs2/background.c +++ b/fs/jffs2/background.c @@ -99,7 +99,13 @@ static int jffs2_garbage_collect_thread(void *_c) if (try_to_freeze()) continue; - cond_resched(); + /* This thread is purely an optimisation. But if it runs when + other things could be running, it actually makes things a + lot worse. Use yield() and put it at the back of the runqueue + every time. Especially during boot, pulling an inode in + with read_inode() is much preferable to having the GC thread + get there first. */ + yield(); /* Put_super will send a SIGKILL and then wait on the sem. */ |