FreeBSD/sys/netinet6/nd6.c
/*
 * ND6 timer routine to handle ND6 entries
 */
ND6 timer routine to handle ND6 entries
ND6 timer routine to handle ND6 entries
static void
nd6_llinfo_settimer_locked(struct llentry *ln, long tick)
{
	int canceled;
	LLE_WLOCK_ASSERT(ln);
	if (tick < 0) {
		ln->la_expire = 0;
		ln->ln_ntick = 0;
		canceled = callout_stop(&ln->lle_timer);
	} else {
		ln->la_expire = time_uptime + tick / hz;
		LLE_ADDREF(ln);
		if (tick > INT_MAX) {
			ln->ln_ntick = tick - INT_MAX;
			canceled = callout_reset(&ln->lle_timer, INT_MAX,
			    nd6_llinfo_timer, ln);
		} else {
			ln->ln_ntick = 0;
			canceled = callout_reset(&ln->lle_timer, tick,
			    nd6_llinfo_timer, ln);
		}
	}
	if (canceled > 0)
		LLE_REMREF(ln);
}
static void nd6_llinfo_settimer_locked ( struct llentry * ln , long tick ) { int canceled ; LLE_WLOCK_ASSERT ( ln ) ; if ( tick < 0 ) { ln -> la_expire = 0 ; ln -> ln_ntick = 0 ; canceled = callout_stop ( & ln -> lle_timer ) ; } else { ln -> la_expire = time_uptime + tick / hz ; LLE_ADDREF ( ln ) ; if ( tick > INT_MAX ) { ln -> ln_ntick = tick - INT_MAX ; canceled = callout_reset ( & ln -> lle_timer , INT_MAX , nd6_llinfo_timer , ln ) ; } else { ln -> ln_ntick = 0 ; canceled = callout_reset ( & ln -> lle_timer , tick , nd6_llinfo_timer , ln ) ; } } if ( canceled > 0 ) LLE_REMREF ( ln ) ; }
ND6 timer routine to handle ND6 entries
ND6 timer routine to handle ND6 entries