Index: head/sys/net/rtsock.c =================================================================== --- head/sys/net/rtsock.c +++ head/sys/net/rtsock.c @@ -900,7 +900,7 @@ error = lla_rt_output(rtm, &info); #ifdef INET6 if (error == 0) - rti_need_deembed = (V_deembed_scopeid) ? 1 : 0; + rti_need_deembed = 1; #endif goto flush; } @@ -915,7 +915,7 @@ error = rib_action(fibnum, rtm->rtm_type, &info, &rc); if (error == 0) { #ifdef INET6 - rti_need_deembed = (V_deembed_scopeid) ? 1 : 0; + rti_need_deembed = 1; #endif rtm->rtm_index = rc.rc_nh_new->nh_ifp->if_index; nh = rc.rc_nh_new; @@ -930,7 +930,7 @@ } #ifdef INET6 /* rt_msg2() will not be used when RTM_DELETE fails. */ - rti_need_deembed = (V_deembed_scopeid) ? 1 : 0; + rti_need_deembed = 1; #endif break; @@ -1192,7 +1192,7 @@ rtinfo->rti_addrs |= (1 << i); dlen = SA_SIZE(sa); #ifdef INET6 - if (V_deembed_scopeid && sa->sa_family == AF_INET6) { + if (sa->sa_family == AF_INET6) { sin6 = (struct sockaddr_in6 *)&ss; bcopy(sa, sin6, sizeof(*sin6)); if (sa6_recoverscope(sin6) == 0) @@ -1298,7 +1298,7 @@ dlen = SA_SIZE(sa); if (cp != NULL && buflen >= dlen) { #ifdef INET6 - if (V_deembed_scopeid && sa->sa_family == AF_INET6) { + if (sa->sa_family == AF_INET6) { sin6 = (struct sockaddr_in6 *)&ss; bcopy(sa, sin6, sizeof(*sin6)); if (sa6_recoverscope(sin6) == 0) Index: head/sys/netinet6/in6.c =================================================================== --- head/sys/netinet6/in6.c +++ head/sys/netinet6/in6.c @@ -2374,8 +2374,7 @@ ndpc.rtm.rtm_type = RTM_GET; ndpc.rtm.rtm_flags = RTF_UP; ndpc.rtm.rtm_addrs = RTA_DST | RTA_GATEWAY; - if (V_deembed_scopeid) - sa6_recoverscope(&ndpc.sin6); + sa6_recoverscope(&ndpc.sin6); /* publish */ if (lle->la_flags & LLE_PUB) Index: head/sys/netinet6/scope6.c =================================================================== --- head/sys/netinet6/scope6.c +++ head/sys/netinet6/scope6.c @@ -60,11 +60,7 @@ #else VNET_DEFINE(int, ip6_use_defzone) = 0; #endif -VNET_DEFINE(int, deembed_scopeid) = 1; SYSCTL_DECL(_net_inet6_ip6); -SYSCTL_INT(_net_inet6_ip6, OID_AUTO, deembed_scopeid, CTLFLAG_VNET | CTLFLAG_RW, - &VNET_NAME(deembed_scopeid), 0, - "Extract embedded zone ID and set it to sin6_scope_id in sockaddr_in6."); /* * The scope6_lock protects the global sid default stored in Index: head/sys/netinet6/scope6_var.h =================================================================== --- head/sys/netinet6/scope6_var.h +++ head/sys/netinet6/scope6_var.h @@ -47,9 +47,6 @@ uint32_t s6id_list[IPV6_ADDR_SCOPES_COUNT]; }; -VNET_DECLARE(int, deembed_scopeid); -#define V_deembed_scopeid VNET(deembed_scopeid) - void scope6_init(void); struct scope6_id *scope6_ifattach(struct ifnet *); void scope6_ifdetach(struct scope6_id *);