svn commit: r215791 - stable/8/sys/netinet
Gleb Smirnoff
glebius at FreeBSD.org
Wed Nov 24 10:55:46 UTC 2010
On Wed, Nov 24, 2010 at 06:11:53PM +1100, Bruce Evans wrote:
B> > +++ stable/8/sys/netinet/if_ether.c Wed Nov 24 05:37:12 2010 (r215791)
B> > @@ -381,7 +381,7 @@ retry:
B> > int canceled;
B> >
B> > LLE_ADDREF(la);
B> > - la->la_expire = time_second + V_arpt_down;
B> > + la->la_expire = time_second;
B> > canceled = callout_reset(&la->la_timer, hz * V_arpt_down,
B> > arptimer, la);
B> > if (canceled)
B> >
B>
B> Isn't using non-monotic time for timeouts always wrong?
Sure it is wrong. I never payed attention to that fact that time_second
could be non-monotic. Is it non-monotic? I failed to understand kern_tc
code at first glance.
B> There are lots of other time_second's in networkining code. These
B> still outnumber time_uptime's by about 68:41. rtcock.c uses the weird
B> expression time_second - time_uptime for metrics. Since time_uptime
B> is relative to boot time while time_second is relative to the Epoch,
B> their difference is approximately the number of seconds since the
B> Epoch, which is a very strange value which might nevertheless be
B> useful for converting between monotonic expiry times and real expiry
B> times, but I think it doesn't work even for that if the real time is
B> stepped.
B>
B> Bruce
--
Totus tuus, Glebius.
More information about the svn-src-stable-8
mailing list