Lines Matching defs:Global_Clatd_Config
37 struct clat_config Global_Clatd_Config;
148 if(Global_Clatd_Config.plat_from_dns64_hostname) {
149 free(Global_Clatd_Config.plat_from_dns64_hostname);
150 Global_Clatd_Config.plat_from_dns64_hostname = NULL;
175 status = plat_prefix(Global_Clatd_Config.plat_from_dns64_hostname,net_id,&tmp_ptr);
177 memcpy(&Global_Clatd_Config.plat_subnet, &tmp_ptr, sizeof(struct in6_addr));
283 if (Global_Clatd_Config.use_dynamic_iid) {
286 &Global_Clatd_Config.ipv4_local_subnet,
287 &Global_Clatd_Config.plat_subnet);
291 interface_ip->s6_addr32[i] = Global_Clatd_Config.ipv6_host_id.s6_addr32[i];
297 * reads the config file and parses it into the global variable Global_Clatd_Config. returns 0 on failure, 1 on success
314 memset(&Global_Clatd_Config, '\0', sizeof(Global_Clatd_Config));
322 Global_Clatd_Config.default_pdp_interface = strdup(uplink_interface);
323 if (!Global_Clatd_Config.default_pdp_interface)
326 if(!config_item_int16_t(root, "mtu", "-1", &Global_Clatd_Config.mtu))
329 if(!config_item_int16_t(root, "ipv4mtu", "-1", &Global_Clatd_Config.ipv4mtu))
333 &Global_Clatd_Config.ipv4_local_subnet))
337 &Global_Clatd_Config.ipv4_local_prefixlen))
341 if(inet_pton(AF_INET6, plat_prefix, &Global_Clatd_Config.plat_subnet) <= 0) {
350 if(!config_item_ip6(root, "plat_subnet", NULL, &Global_Clatd_Config.plat_subnet)) {
357 if(!(Global_Clatd_Config.plat_from_dns64_hostname = config_item_str(root, "plat_from_dns64_hostname", DEFAULT_DNS64_DETECTION_HOSTNAME)))
363 if (!config_item_ip6(root, "ipv6_host_id", "::", &Global_Clatd_Config.ipv6_host_id))
368 if (!IN6_IS_ADDR_UNSPECIFIED(&Global_Clatd_Config.ipv6_host_id)) {
370 ifc_get_info(Global_Clatd_Config.default_pdp_interface, NULL, NULL, &flags);
372 Global_Clatd_Config.use_dynamic_iid = (flags & IFF_BROADCAST) != 0;
374 Global_Clatd_Config.use_dynamic_iid = 1;
391 logmsg(ANDROID_LOG_DEBUG,"mtu = %d",Global_Clatd_Config.mtu);
392 logmsg(ANDROID_LOG_DEBUG,"ipv4mtu = %d",Global_Clatd_Config.ipv4mtu);
393 logmsg(ANDROID_LOG_DEBUG,"ipv6_local_subnet = %s",inet_ntop(AF_INET6, &Global_Clatd_Config.ipv6_local_subnet, charbuffer, sizeof(charbuffer)));
394 logmsg(ANDROID_LOG_DEBUG,"ipv4_local_subnet = %s",inet_ntop(AF_INET, &Global_Clatd_Config.ipv4_local_subnet, charbuffer, sizeof(charbuffer)));
395 logmsg(ANDROID_LOG_DEBUG,"ipv4_local_prefixlen = %d", Global_Clatd_Config.ipv4_local_prefixlen);
396 logmsg(ANDROID_LOG_DEBUG,"plat_subnet = %s",inet_ntop(AF_INET6, &Global_Clatd_Config.plat_subnet, charbuffer, sizeof(charbuffer)));
397 logmsg(ANDROID_LOG_DEBUG,"default_pdp_interface = %s",Global_Clatd_Config.default_pdp_interface);