From: maximilian attems <janitor@sternwelten.at>
To: kernel-janitors@vger.kernel.org
Subject: Re: [Kernel-janitors] [PATCH 2.6.9-rc2 8/33] char/ftape-io: replace
Date: Tue, 21 Sep 2004 20:48:34 +0000 [thread overview]
Message-ID: <20040921204834.GB4260@stro.at> (raw)
In-Reply-To: <20040915225358.GO5778@us.ibm.com>
[-- Attachment #1: Type: text/plain, Size: 1366 bytes --]
On Wed, 15 Sep 2004, Nishanth Aravamudan wrote:
> Any comments would be appreciated.
>
> Description: Use msleep_interruptible() instead of schedule_timeout() to
> guarantee the task delays as expected. In this case, this allowed for
> the removal of the entire do-while.
>
> Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com>
>
> --- 2.6.9-rc2-vanilla/drivers/char/ftape/lowlevel/ftape-io.c 2004-09-13 17:15:47.000000000 -0700
> +++ 2.6.9-rc2/drivers/char/ftape/lowlevel/ftape-io.c 2004-09-14 11:27:06.000000000 -0700
> @@ -96,19 +96,12 @@ void ftape_sleep(unsigned int time)
> timeout = ticks;
> save_flags(flags);
> sti();
> - set_current_state(TASK_INTERRUPTIBLE);
> - do {
> - /* Mmm. Isn't current->blocked == 0xffffffff ?
> - */
> - if (signal_pending(current)) {
> - TRACE(ft_t_err,
> - "awoken by non-blocked signal :-(");
> - break; /* exit on signal */
> - }
> - while (current->state != TASK_RUNNING) {
> - timeout = schedule_timeout(timeout);
> - }
> - } while (timeout);
> + msleep_interruptible(jiffies_to_msecs(timeout));
> + /* Mmm. Isn't current->blocked == 0xffffffff ?
> + */
> + if (signal_pending(current)) {
> + TRACE(ft_t_err, "awoken by non-blocked signal :-(");
> + }
> restore_flags(flags);
> }
> TRACE_EXIT;
this one missed an include too. fixed for next kjt.
a++ maks
[-- Attachment #2: Type: text/plain, Size: 167 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
http://lists.osdl.org/mailman/listinfo/kernel-janitors
prev parent reply other threads:[~2004-09-21 20:48 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-09-15 22:53 [Kernel-janitors] [PATCH 2.6.9-rc2 8/33] char/ftape-io: replace Nishanth Aravamudan
2004-09-21 20:48 ` maximilian attems [this message]
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=20040921204834.GB4260@stro.at \
--to=janitor@sternwelten.at \
--cc=kernel-janitors@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.