mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-01-07 17:17:44 +03:00
network: drop carrier check for unmanaged interface from link_is_ready_to_configure()
Preparation for later commits. No functional change.
This commit is contained in:
parent
d8d4db58ca
commit
2fd3908b5c
@ -98,12 +98,8 @@ bool link_is_ready_to_configure(Link *link, bool allow_unmanaged) {
|
||||
if (!IN_SET(link->state, LINK_STATE_CONFIGURING, LINK_STATE_CONFIGURED, LINK_STATE_UNMANAGED))
|
||||
return false;
|
||||
|
||||
if (!link->network) {
|
||||
if (!allow_unmanaged)
|
||||
return false;
|
||||
|
||||
return link_has_carrier(link);
|
||||
}
|
||||
if (!link->network)
|
||||
return allow_unmanaged;
|
||||
|
||||
if (!link->network->configure_without_carrier) {
|
||||
if (link->set_flags_messages > 0)
|
||||
|
@ -1298,7 +1298,8 @@ static int route_is_ready_to_configure(const Route *route, Link *link) {
|
||||
if (r < 0)
|
||||
return false;
|
||||
if (r > 0) {
|
||||
if (!link_is_ready_to_configure(l, true))
|
||||
if (!link_is_ready_to_configure(l, /* allow_unmanaged = */ true) ||
|
||||
!link_has_carrier(l))
|
||||
return false;
|
||||
|
||||
m->ifindex = l->ifindex;
|
||||
|
Loading…
Reference in New Issue
Block a user