Skip to content

Commit

Permalink
FdbOrch getPort failed because fdb_entry have no switch_id (sonic-net…
Browse files Browse the repository at this point in the history
  • Loading branch information
tylerlinp authored and lguohan committed Apr 11, 2018
1 parent 114faa4 commit 98c084a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions orchagent/fdborch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,7 @@ bool FdbOrch::getPort(const MacAddress& mac, uint16_t vlan, Port& port)
}

sai_fdb_entry_t entry;
entry.switch_id = gSwitchId;
memcpy(entry.mac_address, mac.getMac(), sizeof(sai_mac_t));
entry.bv_id = port.m_vlan_info.vlan_oid;

Expand Down Expand Up @@ -423,6 +424,7 @@ bool FdbOrch::removeFdbEntry(const FdbEntry& entry)

sai_status_t status;
sai_fdb_entry_t fdb_entry;
fdb_entry.switch_id = gSwitchId;
memcpy(fdb_entry.mac_address, entry.mac.getMac(), sizeof(sai_mac_t));
fdb_entry.bv_id = entry.bv_id;

Expand Down

0 comments on commit 98c084a

Please sign in to comment.