lkml.org 
[lkml]   [1999]   [Nov]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subjectlet bdflush to sleep
In my buffer flushing stuff I made bdflush to wakeup each 5 sec. That's
not necessary. bdflush can sleep all the time unless there are too much
dirty buffers.

Patch against 2.3.25pre3:

--- 2.3.25pre3-i386/fs/buffer.c.~1~ Mon Nov 1 18:44:06 1999
+++ 2.3.25pre3-i386/fs/buffer.c Mon Nov 1 18:56:58 1999
@@ -2505,10 +2505,10 @@
/*
* If there are still a lot of dirty buffers around,
* skip the sleep and flush some more. Otherwise, we
- * sleep for a while.
+ * go to sleep waiting a wakeup.
*/
if (balance_dirty_state(NODEV) < 0)
- schedule_timeout(5*HZ);
+ schedule();
/* Remember to mark us as running otherwise
the next schedule will block. */
__set_current_state(TASK_RUNNING);
Andrea



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:54    [W:0.022 / U:0.032 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site