Skip to content

Commit

Permalink
mlxsw: spectrum: Unmap 802.1Q FID before destroying it
Browse files Browse the repository at this point in the history
Before destroying the 802.1Q FID we should first remove the VID-to-FID
mapping. This makes mlxsw_sp_fid_destroy() symmetric with regards to
mlxsw_sp_fid_create().

Fixes: 14d3946 ("mlxsw: spectrum: Use per-FID struct for the VLAN-aware bridge")
Signed-off-by: Ido Schimmel <[email protected]>
Signed-off-by: Jiri Pirko <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
idosch authored and davem330 committed Aug 17, 2016
1 parent 0583272 commit 8168287
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/net/ethernet/mellanox/mlxsw/spectrum_switchdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -450,6 +450,8 @@ void mlxsw_sp_fid_destroy(struct mlxsw_sp *mlxsw_sp, struct mlxsw_sp_fid *f)

kfree(f);

mlxsw_sp_fid_map(mlxsw_sp, fid, false);

mlxsw_sp_fid_op(mlxsw_sp, fid, false);
}

Expand Down

0 comments on commit 8168287

Please sign in to comment.