mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-02-05 22:50:28 +01:00
devices: propagate the hop limit from an IPv6 RA to the kernel config
If we set accept_ra_defrtr=0 then the kernel will ignore the "hop limit" too. So parse it out of the RA and set it manually.
This commit is contained in:
parent
10b699c51f
commit
10a4df690c
1 changed files with 8 additions and 0 deletions
|
|
@ -430,6 +430,7 @@ static const char *ip6_properties_to_save[] = {
|
|||
"accept_ra_pinfo",
|
||||
"accept_ra_rtr_pref",
|
||||
"disable_ipv6",
|
||||
"hop_limit",
|
||||
"use_tempaddr",
|
||||
};
|
||||
|
||||
|
|
@ -3479,6 +3480,13 @@ rdisc_config_changed (NMRDisc *rdisc, NMRDiscConfigMap changed, NMDevice *device
|
|||
}
|
||||
}
|
||||
|
||||
if (changed & NM_RDISC_CONFIG_HOP_LIMIT) {
|
||||
char val[16];
|
||||
|
||||
g_snprintf (val, sizeof (val), "%d", rdisc->hop_limit);
|
||||
nm_device_ipv6_sysctl_set (device, "hop_limit", val);
|
||||
}
|
||||
|
||||
nm_device_activate_schedule_ip6_config_result (device);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue