diff options
author | David S. Miller <davem@davemloft.net> | 2010-12-13 00:55:08 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-12-13 01:08:17 -0500 |
commit | 323e126f0c5995f779d7df7fd035f6e8fed8764d (patch) | |
tree | 402c7267a45ae488363bb1ef8e4c786b65b82572 /include/net/ip.h | |
parent | a02e4b7dae455151c423e2f69ef222c502a321fd (diff) |
ipv4: Don't pre-seed hoplimit metric.
Always go through a new ip4_dst_hoplimit() helper, just like ipv6.
This allowed several simplifications:
1) The interim dst_metric_hoplimit() can go as it's no longer
userd.
2) The sysctl_ip_default_ttl entry no longer needs to use
ipv4_doint_and_flush, since the sysctl is not cached in
routing cache metrics any longer.
3) ipv4_doint_and_flush no longer needs to be exported and
therefore can be marked static.
When ipv4_doint_and_flush_strategy was removed some time ago,
the external declaration in ip.h was mistakenly left around
so kill that off too.
We have to move the sysctl_ip_default_ttl declaration into
ipv4's route cache definition header net/route.h, because
currently net/ip.h (where the declaration lives now) has
a back dependency on net/route.h
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/ip.h')
-rw-r--r-- | include/net/ip.h | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/include/net/ip.h b/include/net/ip.h index 86e2b182a0c0..67fac78a186b 100644 --- a/include/net/ip.h +++ b/include/net/ip.h | |||
@@ -201,7 +201,6 @@ static inline int inet_is_reserved_local_port(int port) | |||
201 | return test_bit(port, sysctl_local_reserved_ports); | 201 | return test_bit(port, sysctl_local_reserved_ports); |
202 | } | 202 | } |
203 | 203 | ||
204 | extern int sysctl_ip_default_ttl; | ||
205 | extern int sysctl_ip_nonlocal_bind; | 204 | extern int sysctl_ip_nonlocal_bind; |
206 | 205 | ||
207 | extern struct ctl_path net_core_path[]; | 206 | extern struct ctl_path net_core_path[]; |
@@ -428,15 +427,6 @@ extern void ip_icmp_error(struct sock *sk, struct sk_buff *skb, int err, | |||
428 | extern void ip_local_error(struct sock *sk, int err, __be32 daddr, __be16 dport, | 427 | extern void ip_local_error(struct sock *sk, int err, __be32 daddr, __be16 dport, |
429 | u32 info); | 428 | u32 info); |
430 | 429 | ||
431 | /* sysctl helpers - any sysctl which holds a value that ends up being | ||
432 | * fed into the routing cache should use these handlers. | ||
433 | */ | ||
434 | int ipv4_doint_and_flush(ctl_table *ctl, int write, | ||
435 | void __user *buffer, | ||
436 | size_t *lenp, loff_t *ppos); | ||
437 | int ipv4_doint_and_flush_strategy(ctl_table *table, | ||
438 | void __user *oldval, size_t __user *oldlenp, | ||
439 | void __user *newval, size_t newlen); | ||
440 | #ifdef CONFIG_PROC_FS | 430 | #ifdef CONFIG_PROC_FS |
441 | extern int ip_misc_proc_init(void); | 431 | extern int ip_misc_proc_init(void); |
442 | #endif | 432 | #endif |