aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/route.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2012-07-10 06:14:24 -0400
committerDavid S. Miller <davem@davemloft.net>2012-07-11 01:40:08 -0400
commit81166dd6fa8eb780b2132d32fbc77eb6ac04e44e (patch)
tree7a41b12950640648d3bb95ca74bfa1391efa0421 /net/ipv4/route.c
parent94334d5ed4b64ebcd2c4b421e133b921f8ccf75d (diff)
tcp: Move timestamps from inetpeer to metrics cache.
With help from Lin Ming. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/route.c')
-rw-r--r--net/ipv4/route.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/net/ipv4/route.c b/net/ipv4/route.c
index d02c91177d32..78d81543766d 100644
--- a/net/ipv4/route.c
+++ b/net/ipv4/route.c
@@ -2846,7 +2846,7 @@ static int rt_fill_info(struct net *net,
2846 struct rtmsg *r; 2846 struct rtmsg *r;
2847 struct nlmsghdr *nlh; 2847 struct nlmsghdr *nlh;
2848 unsigned long expires = 0; 2848 unsigned long expires = 0;
2849 u32 id = 0, ts = 0, tsage = 0, error; 2849 u32 id = 0, error;
2850 2850
2851 nlh = nlmsg_put(skb, pid, seq, event, sizeof(*r), flags); 2851 nlh = nlmsg_put(skb, pid, seq, event, sizeof(*r), flags);
2852 if (nlh == NULL) 2852 if (nlh == NULL)
@@ -2903,10 +2903,6 @@ static int rt_fill_info(struct net *net,
2903 const struct inet_peer *peer = rt_peer_ptr(rt); 2903 const struct inet_peer *peer = rt_peer_ptr(rt);
2904 inet_peer_refcheck(peer); 2904 inet_peer_refcheck(peer);
2905 id = atomic_read(&peer->ip_id_count) & 0xffff; 2905 id = atomic_read(&peer->ip_id_count) & 0xffff;
2906 if (peer->tcp_ts_stamp) {
2907 ts = peer->tcp_ts;
2908 tsage = get_seconds() - peer->tcp_ts_stamp;
2909 }
2910 expires = ACCESS_ONCE(peer->pmtu_expires); 2906 expires = ACCESS_ONCE(peer->pmtu_expires);
2911 if (expires) { 2907 if (expires) {
2912 if (time_before(jiffies, expires)) 2908 if (time_before(jiffies, expires))
@@ -2942,7 +2938,7 @@ static int rt_fill_info(struct net *net,
2942 goto nla_put_failure; 2938 goto nla_put_failure;
2943 } 2939 }
2944 2940
2945 if (rtnl_put_cacheinfo(skb, &rt->dst, id, ts, tsage, 2941 if (rtnl_put_cacheinfo(skb, &rt->dst, id, 0, 0,
2946 expires, error) < 0) 2942 expires, error) < 0)
2947 goto nla_put_failure; 2943 goto nla_put_failure;
2948 2944