From: Nishanth Aravamudan <nacc@us.ibm.com>
To: starvik@axis.com, rmk+serial@arm.linux.org.uk
Cc: akpm@osdl.org, dev-etrax@axis.com, linux-serial@vger.kernel.org
Subject: [-mm PATCH 30/32] serial: fix-up schedule_timeout() usage
Date: Mon, 15 Aug 2005 11:28:52 -0700 [thread overview]
Message-ID: <20050815182852.GG2854@us.ibm.com> (raw)
In-Reply-To: <20050815180514.GC2854@us.ibm.com>
Description: Use schedule_timeout_uninterruptible() instead of
set_current_state()/schedule_timeout() to reduce kernel size.
Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com>
---
drivers/serial/crisv10.c | 9 +++------
1 files changed, 3 insertions(+), 6 deletions(-)
diff -urpN 2.6.13-rc5-mm1/drivers/serial/crisv10.c 2.6.13-rc5-mm1-dev/drivers/serial/crisv10.c
--- 2.6.13-rc5-mm1/drivers/serial/crisv10.c 2005-08-07 09:58:14.000000000 -0700
+++ 2.6.13-rc5-mm1-dev/drivers/serial/crisv10.c 2005-08-10 14:27:46.000000000 -0700
@@ -4417,10 +4417,8 @@ rs_close(struct tty_struct *tty, struct
info->event = 0;
info->tty = 0;
if (info->blocked_open) {
- if (info->close_delay) {
- set_current_state(TASK_INTERRUPTIBLE);
- schedule_timeout(info->close_delay);
- }
+ if (info->close_delay)
+ schedule_timeout_interruptible(info->close_delay);
wake_up_interruptible(&info->open_wait);
}
info->flags &= ~(ASYNC_NORMAL_ACTIVE|ASYNC_CLOSING);
@@ -4470,8 +4468,7 @@ static void rs_wait_until_sent(struct tt
while (info->xmit.head != info->xmit.tail || /* More in send queue */
(*info->ostatusadr & 0x007f) || /* more in FIFO */
(elapsed_usec < 2*info->char_time_usec)) {
- set_current_state(TASK_INTERRUPTIBLE);
- schedule_timeout(1);
+ schedule_timeout_interruptible(1);
if (signal_pending(current))
break;
if (timeout && time_after(jiffies, orig_jiffies + timeout))
parent reply other threads:[~2005-08-15 18:28 UTC|newest]
Thread overview: expand[flat|nested] mbox.gz Atom feed
[parent not found: <20050815180514.GC2854@us.ibm.com>]
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=20050815182852.GG2854@us.ibm.com \
--to=nacc@us.ibm.com \
--cc=akpm@osdl.org \
--cc=dev-etrax@axis.com \
--cc=linux-serial@vger.kernel.org \
--cc=rmk+serial@arm.linux.org.uk \
--cc=starvik@axis.com \
/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;
as well as URLs for NNTP newsgroup(s).