summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--man/sd_event_add_io.xml2
-rw-r--r--src/network/networkd-link.c10
2 files changed, 8 insertions, 4 deletions
diff --git a/man/sd_event_add_io.xml b/man/sd_event_add_io.xml
index e3ac407cdf..4cc0428e29 100644
--- a/man/sd_event_add_io.xml
+++ b/man/sd_event_add_io.xml
@@ -196,7 +196,7 @@
with <function>sd_event_add_io()</function>. It takes the event
source object and the new event mask to set.</para>
- <para><function>sd_event_source_get_io_events()</function>
+ <para><function>sd_event_source_get_io_revents()</function>
retrieves the I/O event mask of currently seen but undispatched
events from an I/O event source created previously with
<function>sd_event_add_io()</function>. It takes the event source
diff --git a/src/network/networkd-link.c b/src/network/networkd-link.c
index 64a4b74e15..a9d91b07f6 100644
--- a/src/network/networkd-link.c
+++ b/src/network/networkd-link.c
@@ -2040,9 +2040,13 @@ static int link_configure(Link *link) {
assert(link->network);
assert(link->state == LINK_STATE_PENDING);
- r = link_drop_foreign_config(link);
- if (r < 0)
- return r;
+ /* Drop foreign config, but ignore loopback device.
+ * We do not want to remove loopback address. */
+ if (!(link->flags & IFF_LOOPBACK)) {
+ r = link_drop_foreign_config(link);
+ if (r < 0)
+ return r;
+ }
r = link_set_bridge_fdb(link);
if (r < 0)