From: Nishanth Aravamudan <nacc@us.ibm.com>
To: netdev@oss.sgi.com
Cc: linux-net@vger.kernel.org, kernel-janitors@lists.osdl.org
Subject: [KJ] [PATCH 19/39] net/dev: replace schedule_timeout() with msleep()
Date: Thu, 20 Jan 2005 15:53:52 -0800 [thread overview]
Message-ID: <20050120235352.GH2600@us.ibm.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 970 bytes --]
Hi,
Please consider applying.
Description: Use msleep() instead of schedule_timeout() to guarantee the task
delays as expected. The current code uses TASK_INTERRUPTIBLE, but does not
respond to signals, so msleep() should be ok.
Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com>
--- 2.6.11-rc1-kj-v/net/core/dev.c 2005-01-15 16:55:44.000000000 -0800
+++ 2.6.11-rc1-kj/net/core/dev.c 2005-01-18 12:59:16.000000000 -0800
@@ -108,6 +108,7 @@
#include <linux/kallsyms.h>
#include <linux/netpoll.h>
#include <linux/rcupdate.h>
+#include <linux/delay.h>
#ifdef CONFIG_NET_RADIO
#include <linux/wireless.h> /* Note : will define WIRELESS_EXT */
#include <net/iw_handler.h>
@@ -2899,8 +2900,7 @@ static void netdev_wait_allrefs(struct n
rebroadcast_time = jiffies;
}
- current->state = TASK_INTERRUPTIBLE;
- schedule_timeout(HZ / 4);
+ msleep(250);
if (time_after(jiffies, warning_time + 10 * HZ)) {
printk(KERN_EMERG "unregister_netdevice: "
[-- 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
next reply other threads:[~2005-01-20 23:53 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-01-20 23:53 Nishanth Aravamudan [this message]
2005-02-09 0:52 ` [PATCH 19/39] net/dev: replace schedule_timeout() with msleep() David S. Miller
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=20050120235352.GH2600@us.ibm.com \
--to=nacc@us.ibm.com \
--cc=kernel-janitors@lists.osdl.org \
--cc=linux-net@vger.kernel.org \
--cc=netdev@oss.sgi.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).