Lines Matching refs:network
25 assert(link->network); in link_get_vrf_table()
27 return link->network->vrf ? VRF(link->network->vrf)->table : RT_TABLE_MAIN; in link_get_vrf_table()
32 assert(link->network); in link_get_dhcp4_route_table()
37 if (link->network->dhcp_route_table_set) in link_get_dhcp4_route_table()
38 return link->network->dhcp_route_table; in link_get_dhcp4_route_table()
44 assert(link->network); in link_get_ipv6_accept_ra_route_table()
46 if (link->network->ipv6_accept_ra_route_table_set) in link_get_ipv6_accept_ra_route_table()
47 return link->network->ipv6_accept_ra_route_table; in link_get_ipv6_accept_ra_route_table()
71 if (!link->network) in link_dhcp_enabled()
74 … return link->network->dhcp & (family == AF_INET ? ADDRESS_FAMILY_IPV4 : ADDRESS_FAMILY_IPV6); in link_dhcp_enabled()
77 void network_adjust_dhcp(Network *network) { in network_adjust_dhcp() argument
78 assert(network); in network_adjust_dhcp()
79 assert(network->dhcp >= 0); in network_adjust_dhcp()
81 if (network->dhcp == ADDRESS_FAMILY_NO) in network_adjust_dhcp()
85 if (network->bond) { in network_adjust_dhcp()
87 network->filename); in network_adjust_dhcp()
88 network->dhcp = ADDRESS_FAMILY_NO; in network_adjust_dhcp()
92 if (!FLAGS_SET(network->link_local, ADDRESS_FAMILY_IPV6) && in network_adjust_dhcp()
93 FLAGS_SET(network->dhcp, ADDRESS_FAMILY_IPV6)) { in network_adjust_dhcp()
95 "Disabling DHCPv6 client.", network->filename); in network_adjust_dhcp()
96 SET_FLAG(network->dhcp, ADDRESS_FAMILY_IPV6, false); in network_adjust_dhcp()
99 network_adjust_dhcp4(network); in network_adjust_dhcp()
116 if (link->network) { in link_get_duid()
117 duid = family == AF_INET ? &link->network->dhcp_duid : &link->network->dhcp6_duid; in link_get_duid()
323 Network *network = userdata; in config_parse_dhcp_or_ra_route_metric() local
342 network->dhcp_route_metric = metric; in config_parse_dhcp_or_ra_route_metric()
343 network->dhcp_route_metric_set = true; in config_parse_dhcp_or_ra_route_metric()
346 network->ipv6_accept_ra_route_metric = metric; in config_parse_dhcp_or_ra_route_metric()
347 network->ipv6_accept_ra_route_metric_set = true; in config_parse_dhcp_or_ra_route_metric()
351 if (!network->dhcp_route_metric_set) in config_parse_dhcp_or_ra_route_metric()
352 network->dhcp_route_metric = metric; in config_parse_dhcp_or_ra_route_metric()
353 if (!network->ipv6_accept_ra_route_metric_set) in config_parse_dhcp_or_ra_route_metric()
354 network->ipv6_accept_ra_route_metric = metric; in config_parse_dhcp_or_ra_route_metric()
375 Network *network = userdata; in config_parse_dhcp_use_dns() local
393 network->dhcp_use_dns = r; in config_parse_dhcp_use_dns()
394 network->dhcp_use_dns_set = true; in config_parse_dhcp_use_dns()
397 network->dhcp6_use_dns = r; in config_parse_dhcp_use_dns()
398 network->dhcp6_use_dns_set = true; in config_parse_dhcp_use_dns()
402 if (!network->dhcp_use_dns_set) in config_parse_dhcp_use_dns()
403 network->dhcp_use_dns = r; in config_parse_dhcp_use_dns()
404 if (!network->dhcp6_use_dns_set) in config_parse_dhcp_use_dns()
405 network->dhcp6_use_dns = r; in config_parse_dhcp_use_dns()
426 Network *network = userdata; in config_parse_dhcp_use_domains() local
444 network->dhcp_use_domains = d; in config_parse_dhcp_use_domains()
445 network->dhcp_use_domains_set = true; in config_parse_dhcp_use_domains()
448 network->dhcp6_use_domains = d; in config_parse_dhcp_use_domains()
449 network->dhcp6_use_domains_set = true; in config_parse_dhcp_use_domains()
453 if (!network->dhcp_use_domains_set) in config_parse_dhcp_use_domains()
454 network->dhcp_use_domains = d; in config_parse_dhcp_use_domains()
455 if (!network->dhcp6_use_domains_set) in config_parse_dhcp_use_domains()
456 network->dhcp6_use_domains = d; in config_parse_dhcp_use_domains()
477 Network *network = userdata; in config_parse_dhcp_use_ntp() local
495 network->dhcp_use_ntp = r; in config_parse_dhcp_use_ntp()
496 network->dhcp_use_ntp_set = true; in config_parse_dhcp_use_ntp()
499 network->dhcp6_use_ntp = r; in config_parse_dhcp_use_ntp()
500 network->dhcp6_use_ntp_set = true; in config_parse_dhcp_use_ntp()
504 if (!network->dhcp_use_ntp_set) in config_parse_dhcp_use_ntp()
505 network->dhcp_use_ntp = r; in config_parse_dhcp_use_ntp()
506 if (!network->dhcp6_use_ntp_set) in config_parse_dhcp_use_ntp()
507 network->dhcp6_use_ntp = r; in config_parse_dhcp_use_ntp()
528 Network *network = userdata; in config_parse_dhcp_or_ra_route_table() local
547 network->dhcp_route_table = rt; in config_parse_dhcp_or_ra_route_table()
548 network->dhcp_route_table_set = true; in config_parse_dhcp_or_ra_route_table()
551 network->ipv6_accept_ra_route_table = rt; in config_parse_dhcp_or_ra_route_table()
552 network->ipv6_accept_ra_route_table_set = true; in config_parse_dhcp_or_ra_route_table()
573 Network *network = userdata; in config_parse_iaid() local
580 assert(network); in config_parse_iaid()
591 network->dhcp_iaid = iaid; in config_parse_iaid()
592 network->dhcp_iaid_set = true; in config_parse_iaid()
593 if (!network->dhcp6_iaid_set_explicitly) { in config_parse_iaid()
596 network->dhcp6_iaid = iaid; in config_parse_iaid()
597 network->dhcp6_iaid_set = true; in config_parse_iaid()
601 network->dhcp6_iaid = iaid; in config_parse_iaid()
602 network->dhcp6_iaid_set = true; in config_parse_iaid()
603 network->dhcp6_iaid_set_explicitly = true; in config_parse_iaid()
918 Network *network = userdata; in config_parse_dhcp_request_options() local
928 network->dhcp_request_options = set_free(network->dhcp_request_options); in config_parse_dhcp_request_options()
930 network->dhcp6_request_options = set_free(network->dhcp6_request_options); in config_parse_dhcp_request_options()
964 …r = set_ensure_put(ltype == AF_INET ? &network->dhcp_request_options : &network->dhcp6_request_opt… in config_parse_dhcp_request_options()
1110 Network *network = userdata; in config_parse_network_duid_type() local
1113 assert(network); in config_parse_network_duid_type()
1115 …e(unit, filename, line, section, section_line, lvalue, true, rvalue, &network->dhcp_duid, network); in config_parse_network_duid_type()
1120 …unit, filename, line, section, section_line, lvalue, false, rvalue, &network->dhcp6_duid, network); in config_parse_network_duid_type()
1235 Network *network = userdata; in config_parse_network_duid_rawdata() local
1238 assert(network); in config_parse_network_duid_rawdata()
1240 …a(unit, filename, line, section, section_line, lvalue, true, rvalue, &network->dhcp_duid, network); in config_parse_network_duid_rawdata()
1245 …unit, filename, line, section, section_line, lvalue, false, rvalue, &network->dhcp6_duid, network); in config_parse_network_duid_rawdata()
1260 Network *network = userdata; in config_parse_uplink() local
1272 index = &network->dhcp_server_uplink_index; in config_parse_uplink()
1273 name = &network->dhcp_server_uplink_name; in config_parse_uplink()
1275 index = &network->router_uplink_index; in config_parse_uplink()
1276 name = &network->router_uplink_name; in config_parse_uplink()
1278 index = &network->dhcp_pd_uplink_index; in config_parse_uplink()
1279 name = &network->dhcp_pd_uplink_name; in config_parse_uplink()