summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorNishanth Aravamudan <nacc@us.ibm.com>2005-09-11 02:09:55 -0700
committerJeff Garzik <jgarzik@pobox.com>2005-09-14 08:33:24 -0400
commit3173c8907ffb2c64456142da3df2bd0500bd59e0 (patch)
treedcd3700a2c37e24a2b5911bb5429aee715684926 /include
parent343c686c04eec556645f251f7d6c9b3d7335dae0 (diff)
downloadop-kernel-dev-3173c8907ffb2c64456142da3df2bd0500bd59e0.zip
op-kernel-dev-3173c8907ffb2c64456142da3df2bd0500bd59e0.tar.gz
[PATCH] drivers/net: fix-up schedule_timeout() usage
Use schedule_timeout_interruptible() instead of set_current_state()/schedule_timeout() to reduce kernel size. Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com> Cc: Jeff Garzik <jgarzik@pobox.com> Cc: "David S. Miller" <davem@davemloft.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/ibmtr.h4
-rw-r--r--include/linux/netdevice.h6
2 files changed, 4 insertions, 6 deletions
diff --git a/include/linux/ibmtr.h b/include/linux/ibmtr.h
index 2ef0b21..1c7a0dd 100644
--- a/include/linux/ibmtr.h
+++ b/include/linux/ibmtr.h
@@ -7,8 +7,8 @@
/* ported to the Alpha architecture 02/20/96 (just used the HZ macro) */
#define TR_RETRY_INTERVAL (30*HZ) /* 500 on PC = 5 s */
-#define TR_RST_TIME (HZ/20) /* 5 on PC = 50 ms */
-#define TR_BUSY_INTERVAL (HZ/5) /* 5 on PC = 200 ms */
+#define TR_RST_TIME (msecs_to_jiffies(50)) /* 5 on PC = 50 ms */
+#define TR_BUSY_INTERVAL (msecs_to_jiffies(200)) /* 5 on PC = 200 ms */
#define TR_SPIN_INTERVAL (3*HZ) /* 3 seconds before init timeout */
#define TR_ISA 1
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 7c71790..98c98e6 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -852,11 +852,9 @@ static inline void netif_rx_complete(struct net_device *dev)
static inline void netif_poll_disable(struct net_device *dev)
{
- while (test_and_set_bit(__LINK_STATE_RX_SCHED, &dev->state)) {
+ while (test_and_set_bit(__LINK_STATE_RX_SCHED, &dev->state))
/* No hurry. */
- current->state = TASK_INTERRUPTIBLE;
- schedule_timeout(1);
- }
+ schedule_timeout_interruptible(1);
}
static inline void netif_poll_enable(struct net_device *dev)
OpenPOWER on IntegriCloud