From: Nishanth Aravamudan <nacc@us.ibm.com>
To: akpm@osdl.org
Cc: linux-kernel@vger.kernel.org
Subject: [-mm PATCH 4/32] mm: fix-up schedule_timeout() usage
Date: Mon, 15 Aug 2005 11:09:08 -0700 [thread overview]
Message-ID: <20050815180908.GG2854@us.ibm.com> (raw)
In-Reply-To: <20050815180514.GC2854@us.ibm.com>
Description: Use schedule_timeout_{,un}interruptible() instead of
set_current_state()/schedule_timeout() to reduce kernel size.
Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com>
---
mm/oom_kill.c | 3 +--
mm/swapfile.c | 3 +--
2 files changed, 2 insertions(+), 4 deletions(-)
diff -urpN 2.6.13-rc5-mm1/mm/oom_kill.c 2.6.13-rc5-mm1-dev/mm/oom_kill.c
--- 2.6.13-rc5-mm1/mm/oom_kill.c 2005-08-07 09:58:16.000000000 -0700
+++ 2.6.13-rc5-mm1-dev/mm/oom_kill.c 2005-08-10 15:23:34.000000000 -0700
@@ -290,6 +290,5 @@ retry:
* Give "p" a good chance of killing itself before we
* retry to allocate memory.
*/
- __set_current_state(TASK_INTERRUPTIBLE);
- schedule_timeout(1);
+ schedule_timeout_interruptible(1);
}
diff -urpN 2.6.13-rc5-mm1/mm/swapfile.c 2.6.13-rc5-mm1-dev/mm/swapfile.c
--- 2.6.13-rc5-mm1/mm/swapfile.c 2005-08-07 10:05:22.000000000 -0700
+++ 2.6.13-rc5-mm1-dev/mm/swapfile.c 2005-08-10 15:23:41.000000000 -0700
@@ -1151,8 +1151,7 @@ asmlinkage long sys_swapoff(const char _
p->highest_bit = 0; /* cuts scans short */
while (p->flags >= SWP_SCANNING) {
spin_unlock(&swap_lock);
- set_current_state(TASK_UNINTERRUPTIBLE);
- schedule_timeout(1);
+ schedule_timeout_uninterruptible(1);
spin_lock(&swap_lock);
}
next prev parent reply other threads:[~2005-08-15 18:09 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-08-15 18:05 [-mm PATCH 0/32] fix-up schedule_timeout() usage Nishanth Aravamudan
2005-08-15 18:06 ` [-mm PATCH 1/32] include: update jiffies/{m,u}secs conversion functions Nishanth Aravamudan
2005-08-17 23:35 ` Andrew Morton
2005-08-18 3:19 ` Nishanth Aravamudan
2005-08-15 18:08 ` [-mm PATCH 2/32] fs: fix-up schedule_timeout() usage Nishanth Aravamudan
2005-08-15 18:17 ` [xfs-masters] " Christoph Hellwig
2005-08-15 18:40 ` Nishanth Aravamudan
2005-08-15 20:36 ` Christoph Hellwig
2005-08-15 18:37 ` Stephen C. Tweedie
2005-08-15 18:08 ` [-mm PATCH 3/32] kernel: " Nishanth Aravamudan
2005-08-15 18:09 ` Nishanth Aravamudan [this message]
2005-08-15 18:18 ` [-mm PATCH 17/32] drivers/cdrom: " Nishanth Aravamudan
2005-08-15 18:19 ` [-mm PATCH 19/32] drivers/dlm: " Nishanth Aravamudan
2005-08-15 18:25 ` [-mm PATCH 26/32] message: " Nishanth Aravamudan
2005-08-15 18:26 ` [-mm PATCH 28/32] drivers/sbus: " Nishanth Aravamudan
2005-08-15 18:29 ` [-mm PATCH 31/32] telephony: " Nishanth Aravamudan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20050815180908.GG2854@us.ibm.com \
--to=nacc@us.ibm.com \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox