mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-09 21:04:42 -04:00
net/mlx5: Avoid unnecessary operation
fs_get_obj retrieves the container of fs_parent_node just to pass the same value as &fs_ns->node. Just pass fs_parent_node to init_root_tree_recursive() to get exactly the same effect. Signed-off-by: Eli Cohen <elic@nvidia.com> Reviewed-by: Roi Dayan <roid@nvidia.com> Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
This commit is contained in:
committed by
Saeed Mahameed
parent
03e219c4cf
commit
61e9508f1e
@@ -2395,14 +2395,12 @@ static int init_root_tree(struct mlx5_flow_steering *steering,
|
||||
struct init_tree_node *init_node,
|
||||
struct fs_node *fs_parent_node)
|
||||
{
|
||||
int i;
|
||||
struct mlx5_flow_namespace *fs_ns;
|
||||
int err;
|
||||
int i;
|
||||
|
||||
fs_get_obj(fs_ns, fs_parent_node);
|
||||
for (i = 0; i < init_node->ar_size; i++) {
|
||||
err = init_root_tree_recursive(steering, &init_node->children[i],
|
||||
&fs_ns->node,
|
||||
fs_parent_node,
|
||||
init_node, i);
|
||||
if (err)
|
||||
return err;
|
||||
|
||||
Reference in New Issue
Block a user