Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

issue: 2394023 Fix active-backup failover_mac=1 RX #924

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/vma/dev/net_device_val.h
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,7 @@ class net_device_val
L2_address* get_l2_address() { return m_p_L2_addr; };
L2_address* get_br_address() { return m_p_br_addr; };
inline bond_type get_is_bond() { return m_bond; }
inline int get_fail_over_mac() { return m_bond_fail_over_mac; }
inline bond_xmit_hash_policy get_bond_xmit_hash_policy() { return m_bond_xmit_hash_policy; }
bool update_active_slaves();
void update_netvsc_slaves(int if_index, int if_flags);
Expand Down
11 changes: 11 additions & 0 deletions src/vma/dev/ring_bond.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -837,6 +837,17 @@ int ring_bond::socketxtreme_poll(struct vma_completion_t *, unsigned int, int)
void ring_bond::check_roce_lag_mode(const slave_data_vector_t& slaves)
{
#if defined(DEFINED_ROCE_LAG)
if (m_type == net_device_val::ACTIVE_BACKUP) {
net_device_val *p_ndev = g_p_net_device_table_mgr->get_net_device_val(m_parent->get_if_index());
if (p_ndev->get_fail_over_mac() > 0) {
/*
* Skip active-backup mode with failover_mac=1
* because we have to create rules for all MAC
* addresses.
*/
return;
}
}
m_b_roce_lag = slaves.size() > 1;
for (uint32_t i = 1; i < slaves.size(); i++) {
if (slaves[i]->p_ib_ctx != slaves[0]->p_ib_ctx) {
Expand Down