diff options
author | Nishanth Aravamudan <nacc@us.ibm.com> | 2005-09-12 17:15:34 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2005-09-12 17:15:34 -0400 |
commit | 121caf577dc61588c1128821873a08cec48baf58 (patch) | |
tree | 751e2e6bf9b58aa4b40e8285d357b0cf083ae8cc /net/ipv4/ipconfig.c | |
parent | 7672d0b54411371e0b6a831c1cb2f0ce615de6dc (diff) |
[NET]: fix-up schedule_timeout() usage
Use schedule_timeout_{,un}interruptible() instead of
set_current_state()/schedule_timeout() to reduce kernel size. Also use
human-time conversion functions instead of hard-coded division to avoid
rounding issues.
Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/ipconfig.c')
-rw-r--r-- | net/ipv4/ipconfig.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/net/ipv4/ipconfig.c b/net/ipv4/ipconfig.c index 953129d392d2..e8674baaa8d9 100644 --- a/net/ipv4/ipconfig.c +++ b/net/ipv4/ipconfig.c | |||
@@ -1103,10 +1103,8 @@ static int __init ic_dynamic(void) | |||
1103 | #endif | 1103 | #endif |
1104 | 1104 | ||
1105 | jiff = jiffies + (d->next ? CONF_INTER_TIMEOUT : timeout); | 1105 | jiff = jiffies + (d->next ? CONF_INTER_TIMEOUT : timeout); |
1106 | while (time_before(jiffies, jiff) && !ic_got_reply) { | 1106 | while (time_before(jiffies, jiff) && !ic_got_reply) |
1107 | set_current_state(TASK_UNINTERRUPTIBLE); | 1107 | schedule_timeout_uninterruptible(1); |
1108 | schedule_timeout(1); | ||
1109 | } | ||
1110 | #ifdef IPCONFIG_DHCP | 1108 | #ifdef IPCONFIG_DHCP |
1111 | /* DHCP isn't done until we get a DHCPACK. */ | 1109 | /* DHCP isn't done until we get a DHCPACK. */ |
1112 | if ((ic_got_reply & IC_BOOTP) | 1110 | if ((ic_got_reply & IC_BOOTP) |