public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Nishanth Aravamudan <nacc@us.ibm.com>
To: Nish Aravamudan <nish.aravamudan@gmail.com>
Cc: Willem Riede <osst@riede.org>,
	kernel-janitors@lists.osdl.org, osst-users@lists.sourceforge.net,
	linux-scsi@vger.kernel.org
Subject: Re: [Kernel-janitors] [PATCH] Re: no set_current_state() before schedule_timeout() (OSST)
Date: Tue, 13 Jul 2004 23:56:41 +0000	[thread overview]
Message-ID: <40F476B9.4090101@us.ibm.com> (raw)
In-Reply-To: <29495f1d04071316362e782433@mail.gmail.com>

Nish Aravamudan wrote:
> On Tue, 13 Jul 2004 23:07:32 +0000, Willem Riede <osst@riede.org> wrote:
> 
>>
>>On 07/13/2004 01:40:54 PM, Nishanth Aravamudan wrote:
> 
> 
> <snip>
> 
>>>If someone could tell me which state (TASK_INTERRUPTIBLE or
>>>TASK_UNINTERRUPTIBLE) is desired, I can fix this and perhaps replace the
>>>calls with msleep().
>>
>>You're right, there is a set_current_state(TASK_INTERRUPTIBLE) missing.
>>I don't know why we would want to change to use msleep() though.
> 
> 
> <snip>
> 
> The main reason I see for using msleep() instead is if the task should
> sleep for at least 100 ms. Using TASK_INTERRUPTIBLE (or really
> anything other than msleep()) is not guaranteed to sleep as long as
> requested. If that's ok / desired, then I won't convert it, of course.

To be clear, the 100 ms I mention above is specific to this example. In 
general, if the time you want to sleep (and you really want to *sleep* 
for that time) is measureable in msecs, then msleep() is the way to go.

-Nish


  reply	other threads:[~2004-07-13 23:57 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-07-13 17:40 no set_current_state() before schedule_timeout() (OSST) Nishanth Aravamudan
2004-07-13 23:07 ` [PATCH] " Willem Riede
2004-07-13 23:36   ` [Kernel-janitors] " Nish Aravamudan
2004-07-13 23:56     ` Nishanth Aravamudan [this message]
2004-07-14  0:45     ` Willem Riede

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=40F476B9.4090101@us.ibm.com \
    --to=nacc@us.ibm.com \
    --cc=kernel-janitors@lists.osdl.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=nish.aravamudan@gmail.com \
    --cc=osst-users@lists.sourceforge.net \
    --cc=osst@riede.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