* [PATCH 2/2] [IPV{4,6}] Normalize jiffies values reported to userspace
@ 2003-11-09 21:59 YOSHIFUJI Hideaki / 吉藤英明
2003-11-10 3:25 ` David S. Miller
0 siblings, 1 reply; 2+ messages in thread
From: YOSHIFUJI Hideaki / 吉藤英明 @ 2003-11-09 21:59 UTC (permalink / raw)
To: davem; +Cc: netdev
Hello.
[2/2] [IPV{4,6}] Normalize jiffies values reported to userspace
===== net/ipv4/route.c 1.73 vs edited =====
--- 1.73/net/ipv4/route.c Tue Oct 7 23:54:12 2003
+++ edited/net/ipv4/route.c Mon Nov 10 06:34:08 2003
@@ -89,6 +89,7 @@
#include <linux/random.h>
#include <linux/jhash.h>
#include <linux/rcupdate.h>
+#include <linux/times.h>
#include <net/protocol.h>
#include <net/ip.h>
#include <net/route.h>
@@ -2309,7 +2310,7 @@
ci.rta_used = rt->u.dst.__use;
ci.rta_clntref = atomic_read(&rt->u.dst.__refcnt);
if (rt->u.dst.expires)
- ci.rta_expires = rt->u.dst.expires - jiffies;
+ ci.rta_expires = jiffies_to_clock_t(rt->u.dst.expires - jiffies);
else
ci.rta_expires = 0;
ci.rta_error = rt->u.dst.error;
===== net/ipv6/route.c 1.58 vs edited =====
--- 1.58/net/ipv6/route.c Sun Aug 31 13:26:12 2003
+++ edited/net/ipv6/route.c Mon Nov 10 06:34:08 2003
@@ -27,6 +27,7 @@
#include <linux/config.h>
#include <linux/errno.h>
#include <linux/types.h>
+#include <linux/times.h>
#include <linux/socket.h>
#include <linux/sockios.h>
#include <linux/net.h>
@@ -717,7 +718,7 @@
return -ENOMEM;
rt->u.dst.obsolete = -1;
- rt->rt6i_expires = rtmsg->rtmsg_info;
+ rt->rt6i_expires = clock_t_to_jiffies(rtmsg->rtmsg_info);
if (nlh && (r = NLMSG_DATA(nlh))) {
rt->rt6i_protocol = r->rtm_protocol;
} else {
@@ -1535,7 +1536,7 @@
RTA_PUT(skb, RTA_PRIORITY, 4, &rt->rt6i_metric);
ci.rta_lastuse = jiffies - rt->u.dst.lastuse;
if (rt->rt6i_expires)
- ci.rta_expires = rt->rt6i_expires - jiffies;
+ ci.rta_expires = jiffies_to_clock_t(rt->rt6i_expires - jiffies);
else
ci.rta_expires = 0;
ci.rta_used = rt->u.dst.__use;
--
Hideaki YOSHIFUJI @ USAGI Project <yoshfuji@linux-ipv6.org>
GPG FP: 9022 65EB 1ECF 3AD1 0BDF 80D8 4807 F894 E062 0EEA
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH 2/2] [IPV{4,6}] Normalize jiffies values reported to userspace
2003-11-09 21:59 [PATCH 2/2] [IPV{4,6}] Normalize jiffies values reported to userspace YOSHIFUJI Hideaki / 吉藤英明
@ 2003-11-10 3:25 ` David S. Miller
0 siblings, 0 replies; 2+ messages in thread
From: David S. Miller @ 2003-11-10 3:25 UTC (permalink / raw)
To: YOSHIFUJI Hideaki / _$B5HF#1QL@; +Cc: netdev
On Sun, 09 Nov 2003 15:59:52 -0600 (CST)
YOSHIFUJI Hideaki / _$B5HF#1QL@ <yoshfuji@linux-ipv6.org> wrote:
> [1/1] linux/times.h needs asm/param.h
> [2/2] [IPV{4,6}] Normalize jiffies values reported to userspace
Both patches applied, arigato Yoshfuji-san.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2003-11-10 3:25 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-11-09 21:59 [PATCH 2/2] [IPV{4,6}] Normalize jiffies values reported to userspace YOSHIFUJI Hideaki / 吉藤英明
2003-11-10 3:25 ` David S. Miller
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).