network: fix DHCPv4 address renewal with IPv4ACD

Previously, when a DHCP address is renewed and if the IPv4ACD for the
address is enabled, the address will never drop the probing flag, thus
the lifetime of the address will never be updated.

This drops NETWORK_CONFIG_STATE_PROBING, and the IPv4ACD status is
managed another bit, Address.acd_bound. And, the flag is updated only
when the IPv4ACD announced the address or detects conflict.
This commit is contained in:
Yu Watanabe
2022-08-18 15:44:23 +09:00
parent 5ad8116a87
commit e402e99eaa
6 changed files with 46 additions and 44 deletions
-1
View File
@@ -26,7 +26,6 @@ DEFINE_STRING_TABLE_LOOKUP_TO_STRING(network_config_source, NetworkConfigSource)
int network_config_state_to_string_alloc(NetworkConfigState s, char **ret) {
static const char* states[] = {
[LOG2U(NETWORK_CONFIG_STATE_PROBING)] = "probing",
[LOG2U(NETWORK_CONFIG_STATE_REQUESTING)] = "requesting",
[LOG2U(NETWORK_CONFIG_STATE_CONFIGURING)] = "configuring",
[LOG2U(NETWORK_CONFIG_STATE_CONFIGURED)] = "configured",