chiark / gitweb /
networkd: link - don't enforce ENSLAVING state
authorTom Gundersen <teg@jklm.no>
Tue, 19 Aug 2014 15:50:38 +0000 (17:50 +0200)
committerTom Gundersen <teg@jklm.no>
Tue, 19 Aug 2014 15:55:34 +0000 (17:55 +0200)
We are only guaranteed to stay in ENSLAVING state whilst enslaving by bridges/bonds, not
when adding stacked devices (as then the underlying device can be IFF_UP'ed and configured
in parallel), so drop these asserts.

src/network/networkd-link.c

index 248022133f475a00bc65a66d749f32aee708cf6e..b5f5863e6b60ac79bbfe64fef635994aa0442605 100644 (file)
@@ -1052,7 +1052,6 @@ static int link_joined(Link *link) {
         int r;
 
         assert(link);
-        assert(link->state == LINK_STATE_ENSLAVING);
         assert(link->network);
 
         if (!(link->flags & IFF_UP)) {
@@ -1072,8 +1071,6 @@ static int netdev_join_handler(sd_rtnl *rtnl, sd_rtnl_message *m,
         int r;
 
         assert(link);
-        assert(IN_SET(link->state, LINK_STATE_ENSLAVING, LINK_STATE_FAILED,
-                      LINK_STATE_LINGER));
         assert(link->network);
 
         link->enslaving --;