summaryrefslogtreecommitdiffstats
path: root/mm/vmscan.c
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2000-02-23 00:40:54 +0000
committerRalf Baechle <ralf@linux-mips.org>2000-02-23 00:40:54 +0000
commit529c593ece216e4aaffd36bd940cb94f1fa63129 (patch)
tree78f1c0b805f5656aa7b0417a043c5346f700a2cf /mm/vmscan.c
parent0bd079751d25808d1972baee5c4eaa1db2227257 (diff)
Merge with 2.3.43. I did ignore all modifications to the qlogicisp.c
driver due to the Origin A64 hacks.
Diffstat (limited to 'mm/vmscan.c')
-rw-r--r--mm/vmscan.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/mm/vmscan.c b/mm/vmscan.c
index 231cbf8f7..e6cb394d9 100644
--- a/mm/vmscan.c
+++ b/mm/vmscan.c
@@ -451,7 +451,7 @@ done:
return priority >= 0;
}
-static struct task_struct *kswapd_process;
+DECLARE_WAIT_QUEUE_HEAD(kswapd_wait);
/*
* The background pageout daemon, started as a kernel thread
@@ -471,7 +471,6 @@ int kswapd(void *unused)
{
struct task_struct *tsk = current;
- kswapd_process = tsk;
tsk->session = 1;
tsk->pgrp = 1;
strcpy(tsk->comm, "kswapd");
@@ -510,7 +509,7 @@ int kswapd(void *unused)
run_task_queue(&tq_disk);
} while (!tsk->need_resched);
tsk->state = TASK_INTERRUPTIBLE;
- schedule_timeout(HZ);
+ interruptible_sleep_on(&kswapd_wait);
}
}
@@ -533,7 +532,6 @@ int try_to_free_pages(unsigned int gfp_mask, zone_t *zone)
{
int retval = 1;
- wake_up_process(kswapd_process);
if (gfp_mask & __GFP_WAIT) {
current->flags |= PF_MEMALLOC;
retval = do_try_to_free_pages(gfp_mask, zone);