Merge pull request #9789 from idryzhov/if-ll-type

lib: set type for newly created interfaces
This commit is contained in:
Mark Stapp 2021-10-11 08:57:26 -04:00 committed by GitHub
commit e2c3eaddd5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1832,6 +1832,8 @@ int netlink_link_change(struct nlmsghdr *h, ns_id_t ns_id, int startup)
/* Update link. */
zebra_if_update_link(ifp, link_ifindex, ns_id);
ifp->ll_type =
netlink_to_zebra_link_type(ifi->ifi_type);
netlink_interface_update_hw_addr(tb, ifp);
/* Inform clients, install any configured addresses. */
@ -1899,6 +1901,8 @@ int netlink_link_change(struct nlmsghdr *h, ns_id_t ns_id, int startup)
/* Update link. */
zebra_if_update_link(ifp, link_ifindex, ns_id);
ifp->ll_type =
netlink_to_zebra_link_type(ifi->ifi_type);
netlink_interface_update_hw_addr(tb, ifp);
if (if_is_no_ptm_operative(ifp)) {