net/mlx5: Bridge, extract code to lookup parent bridge of port
The pattern when function looks up a port by vport_num+vhca_id tuple in order to just obtain its parent bridge is repeated multiple times in bridge.c file. Further commits in this series use the pattern even more. Extract the pattern to standalone mlx5_esw_bridge_from_port_lookup() function to improve code readability. This commits doesn't change functionality. Signed-off-by: Vlad Buslov <vladbu@nvidia.com> Reviewed-by: Maor Dickman <maord@nvidia.com> Reviewed-by: Roi Dayan <roid@nvidia.com> Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
Showing
Please register or sign in to comment