Skip to contentSkip to conversation

fs/xfs_buf: replace schedule_timeout() with

PATCH In review Nishanth Aravamudan 1 participant 1 message Jan 20, 2005

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 11/40 fs/xfs_buf: replace schedule_timeout() with

Hi,

Please consider applying.

Description: Use msleep() instead of schedule_timeout() to guarantee the task delays as expected. The current code uses TASK_INTERRUPTIBLE, but does not check for signals, so I believe the change to msleep() is appropriate.

fs/xfs/linux-2.6/xfs_buf.c +2 -2
@@ -54,6 +54,7 @@
 #include <linux/suspend.h>
 #include <linux/percpu.h>
 #include <linux/blkdev.h>
+#include <linux/delay.h>
 
 #include "xfs_linux.h"
 
@@ -1689,8 +1690,7 @@ pagebuf_daemon(
 		if (current->flags & PF_FREEZE)
 			refrigerator(PF_FREEZE);
 
-		set_current_state(TASK_INTERRUPTIBLE);
-		schedule_timeout((xfs_buf_timer_centisecs * HZ) / 100);
+		msleep(xfs_buf_timer_centisecs * 10);
 
 		age = (xfs_buf_age_centisecs * HZ) / 100;
 		spin_lock(&pbd_delwrite_lock);

_______________________________________________
Kernel-janitors mailing list
[email protected]
http://lists.osdl.org/mailman/listinfo/kernel-janitors