]> git.puffer.fish Git - matthieu/frr.git/commitdiff
zebra: remove ZEBRA_IF_BOND_SLAVE interface type
authorIgor Ryzhov <iryzhov@nfware.com>
Wed, 17 May 2023 17:30:02 +0000 (17:30 +0000)
committerIgor Ryzhov <iryzhov@nfware.com>
Sun, 21 May 2023 20:37:39 +0000 (23:37 +0300)
It is never actually used in the code.

Closes #13532.

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
zebra/if_netlink.c
zebra/interface.c
zebra/interface.h

index fcb692b715fe589c74324c8cb528af8d2f92f6aa..cd200d821d7ae369bbf5f3b76798ef3ef732ba12 100644 (file)
@@ -279,8 +279,6 @@ static void netlink_determine_zebra_iftype(const char *kind,
                *zif_type = ZEBRA_IF_VETH;
        else if (strcmp(kind, "bond") == 0)
                *zif_type = ZEBRA_IF_BOND;
-       else if (strcmp(kind, "bond_slave") == 0)
-               *zif_type = ZEBRA_IF_BOND_SLAVE;
        else if (strcmp(kind, "gre") == 0)
                *zif_type = ZEBRA_IF_GRE;
 }
@@ -1120,10 +1118,7 @@ static int netlink_interface(struct nlmsghdr *h, ns_id_t ns_id, int startup)
                if (linkinfo[IFLA_INFO_SLAVE_KIND])
                        slave_kind = RTA_DATA(linkinfo[IFLA_INFO_SLAVE_KIND]);
 
-               if ((slave_kind != NULL) && strcmp(slave_kind, "bond") == 0)
-                       netlink_determine_zebra_iftype("bond_slave", &zif_type);
-               else
-                       netlink_determine_zebra_iftype(kind, &zif_type);
+               netlink_determine_zebra_iftype(kind, &zif_type);
        }
 
        /* If VRF, create the VRF structure itself. */
index 231ddc51dbec169052480665ab7648778a3b9761..2585d0dc32902366a5e440b6c90d2d48b39ed8dd 100644 (file)
@@ -1697,9 +1697,6 @@ static const char *zebra_ziftype_2str(enum zebra_iftype zif_type)
        case ZEBRA_IF_BOND:
                return "bond";
 
-       case ZEBRA_IF_BOND_SLAVE:
-               return "bond_slave";
-
        case ZEBRA_IF_MACVLAN:
                return "macvlan";
 
index e5545d6ba0895826ccdda777ee94050ef7116fb5..8cbdd349d183b26974bf1055c97356bb0176b7e5 100644 (file)
@@ -39,7 +39,6 @@ enum zebra_iftype {
        ZEBRA_IF_MACVLAN,   /* MAC VLAN interface*/
        ZEBRA_IF_VETH,      /* VETH interface*/
        ZEBRA_IF_BOND,      /* Bond */
-       ZEBRA_IF_BOND_SLAVE,        /* Bond */
        ZEBRA_IF_GRE,      /* GRE interface */
 };