From: Nishanth Aravamudan <nacc@us.ibm.com>
To: linux-kernel@vger.kernel.org
Subject: FW: [KJ] ftape/fdc-io: schedule_timeout() usage
Date: Thu, 6 Jan 2005 16:17:15 -0800 [thread overview]
Message-ID: <20050107001715.GG3055@us.ibm.com> (raw)
I haven't had any replies so far, and it was suggested that I also fish on LKML
for input.
Thanks,
Nish
----- Forwarded message from Nishanth Aravamudan <nacc@us.ibm.com> -----
Date: Wed, 5 Jan 2005 16:14:00 -0800
From: Nishanth Aravamudan <nacc@us.ibm.com>
To: linux-tape@vger.kernel.org
Cc: kernel-janitors@lists.osdl.org
Subject: [KJ] ftape/fdc-io: schedule_timeout() usage
Hello,
I'm hoping someone here can help me correct some ftape code.
drivers/char/ftape/lowlevel/fdc-io.c::fdc_interrupt_wait() contains the
following code:
set_current_state(TASK_INTERRUPTIBLE);
add_wait_queue((&ftape_wait_intr, &wait);
while (!ft_interrupt_seen && (current->state == TASK_INTERRUPTIBLE)) {
timeout = schedule_timeout(timeout);
}
The problem I have is that after the first iteration of the loop
(schedule_timeout() with TASK_INTERRUPTIBLE), it will become a busy-wait, as
schedule_timeout() will be running with current->state set to TASK_RUNNING. I'm
not sure if this is desired, but it seems weird to me. Any input would be
appreciated.
-Nish
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
http://lists.osdl.org/mailman/listinfo/kernel-janitors
----- End forwarded message -----
reply other threads:[~2005-01-07 0:28 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20050107001715.GG3055@us.ibm.com \
--to=nacc@us.ibm.com \
--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 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.