Changeset View
Changeset View
Standalone View
Standalone View
sys/netinet6/in6.c
Show First 20 Lines • Show All 2,208 Lines • ▼ Show 20 Lines | if (nh && ((nh->nh_flags & NHF_GATEWAY) || nh->nh_ifp != ifp)) { | ||||
} | } | ||||
log(LOG_INFO, "IPv6 address: \"%s\" is not on the network\n", | log(LOG_INFO, "IPv6 address: \"%s\" is not on the network\n", | ||||
ip6_sprintf(ip6buf, &sin6->sin6_addr)); | ip6_sprintf(ip6buf, &sin6->sin6_addr)); | ||||
return EINVAL; | return EINVAL; | ||||
} | } | ||||
return 0; | return 0; | ||||
} | } | ||||
/* | |||||
* Called by the datapath to indicate that the entry was used. | |||||
*/ | |||||
static void | |||||
in6_lltable_mark_used(struct llentry *lle) | |||||
{ | |||||
LLE_REQ_LOCK(lle); | |||||
lle->r_skip_req = 0; | |||||
/* | |||||
* Set the hit time so the callback function | |||||
* can determine the remaining time before | |||||
* transiting to the DELAY state. | |||||
*/ | |||||
lle->lle_hittime = time_uptime; | |||||
LLE_REQ_UNLOCK(lle); | |||||
} | |||||
static inline uint32_t | static inline uint32_t | ||||
in6_lltable_hash_dst(const struct in6_addr *dst, uint32_t hsize) | in6_lltable_hash_dst(const struct in6_addr *dst, uint32_t hsize) | ||||
{ | { | ||||
return (IN6_LLTBL_HASH(dst->s6_addr32[3], hsize)); | return (IN6_LLTBL_HASH(dst->s6_addr32[3], hsize)); | ||||
} | } | ||||
static uint32_t | static uint32_t | ||||
▲ Show 20 Lines • Show All 220 Lines • ▼ Show 20 Lines | in6_lltattach(struct ifnet *ifp) | ||||
llt->llt_lookup = in6_lltable_lookup; | llt->llt_lookup = in6_lltable_lookup; | ||||
llt->llt_alloc_entry = in6_lltable_alloc; | llt->llt_alloc_entry = in6_lltable_alloc; | ||||
llt->llt_delete_entry = in6_lltable_delete_entry; | llt->llt_delete_entry = in6_lltable_delete_entry; | ||||
llt->llt_dump_entry = in6_lltable_dump_entry; | llt->llt_dump_entry = in6_lltable_dump_entry; | ||||
llt->llt_hash = in6_lltable_hash; | llt->llt_hash = in6_lltable_hash; | ||||
llt->llt_fill_sa_entry = in6_lltable_fill_sa_entry; | llt->llt_fill_sa_entry = in6_lltable_fill_sa_entry; | ||||
llt->llt_free_entry = in6_lltable_free_entry; | llt->llt_free_entry = in6_lltable_free_entry; | ||||
llt->llt_match_prefix = in6_lltable_match_prefix; | llt->llt_match_prefix = in6_lltable_match_prefix; | ||||
llt->llt_mark_used = in6_lltable_mark_used; | llt->llt_mark_used = llentry_mark_used; | ||||
lltable_link(llt); | lltable_link(llt); | ||||
return (llt); | return (llt); | ||||
} | } | ||||
void * | void * | ||||
in6_domifattach(struct ifnet *ifp) | in6_domifattach(struct ifnet *ifp) | ||||
{ | { | ||||
▲ Show 20 Lines • Show All 117 Lines • Show Last 20 Lines |