From: Vratko Polak Date: Fri, 2 May 2025 15:04:58 +0000 (+0200) Subject: bonding: activate also on port-rx-eth arc X-Git-Tag: v25.10-rc0~31 X-Git-Url: https://gerrit.fd.io/r/gitweb?a=commitdiff_plain;h=fa221bcada66e6cba8e5ab12ef0d8fc077e47094;p=vpp.git bonding: activate also on port-rx-eth arc CSIT tests bonding with AVF, but no longer with plugins/avf. And plugins/dev_iavf is sensitive only to port-rx-eth arc, not to device-input arc. Not sure changing bonding is the correct fix, but it is easier than making vnet/dev work on device-input arc. - The indentation is a compromise with "make fixstyle". Ticket: vpp-3602 Type: fix Change-Id: I9744d9560661cae208a273155aee7e1b3decdd15 Signed-off-by: Vratko Polak --- diff --git a/src/vnet/bonding/cli.c b/src/vnet/bonding/cli.c index 33a313b8052..60c8541f35b 100644 --- a/src/vnet/bonding/cli.c +++ b/src/vnet/bonding/cli.c @@ -308,6 +308,9 @@ bond_delete_neighbor (vlib_main_t * vm, bond_if_t * bif, member_if_t * mif) vnet_feature_enable_disable ("device-input", "bond-input", mif->sw_if_index, 0, 0, 0); + vnet_feature_enable_disable ("port-rx-eth", "bond-input", mif->sw_if_index, + 0, 0, 0); + /* Put back the old mac */ vnet_hw_interface_change_mac_address (vnm, mif_hw->hw_if_index, mif->persistent_hw_address); @@ -762,13 +765,20 @@ bond_add_member (vlib_main_t * vm, bond_add_member_args_t * args) args->rv = vnet_feature_enable_disable ("device-input", "bond-input", mif->sw_if_index, 1, 0, 0); + if (args->rv) + { + args->error = clib_error_return ( + 0, "Error encountered on device input feature arc enable"); + } + + args->rv = vnet_feature_enable_disable ("port-rx-eth", "bond-input", + mif->sw_if_index, 1, 0, 0); if (args->rv) - { - args->error = - clib_error_return (0, - "Error encountered on input feature arc enable"); - } + { + args->error = + clib_error_return (0, "Error encountered on port rx feature arc enable"); + } } static clib_error_t * diff --git a/src/vnet/bonding/node.c b/src/vnet/bonding/node.c index 347aa56dbc0..821535d7afe 100644 --- a/src/vnet/bonding/node.c +++ b/src/vnet/bonding/node.c @@ -414,13 +414,18 @@ VLIB_REGISTER_NODE (bond_input_node) = { VLIB_INIT_FUNCTION (bond_input_init); -VNET_FEATURE_INIT (bond_input, static) = -{ +VNET_FEATURE_INIT (bond_input_device, static) = { .arc_name = "device-input", .node_name = "bond-input", .runs_before = VNET_FEATURES ("ethernet-input"), }; +VNET_FEATURE_INIT (bond_input_rx, static) = { + .arc_name = "port-rx-eth", + .node_name = "bond-input", + .runs_before = VNET_FEATURES ("ethernet-input"), +}; + static clib_error_t * bond_sw_interface_up_down (vnet_main_t * vnm, u32 sw_if_index, u32 flags) {