net/mlx5e: Remove redundant actions arg from vlan push/pop funcs
Passing actions is redundant and can be retrieved from flow attr. Signed-off-by: Roi Dayan <roid@nvidia.com> Reviewed-by: Oz Shlomo <ozsh@nvidia.com> Reviewed-by: Maor Dickman <maord@nvidia.com> Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
This commit is contained in:
parent
3cc78411f3
commit
70a140ea6f
@ -3682,7 +3682,6 @@ static struct net_device *get_fdb_out_dev(struct net_device *uplink_dev,
|
||||
static int add_vlan_push_action(struct mlx5e_priv *priv,
|
||||
struct mlx5_flow_attr *attr,
|
||||
struct net_device **out_dev,
|
||||
u32 *action,
|
||||
struct netlink_ext_ack *extack)
|
||||
{
|
||||
struct net_device *vlan_dev = *out_dev;
|
||||
@ -3694,7 +3693,7 @@ static int add_vlan_push_action(struct mlx5e_priv *priv,
|
||||
};
|
||||
int err;
|
||||
|
||||
err = parse_tc_vlan_action(priv, &vlan_act, attr->esw_attr, action, extack);
|
||||
err = parse_tc_vlan_action(priv, &vlan_act, attr->esw_attr, &attr->action, extack);
|
||||
if (err)
|
||||
return err;
|
||||
|
||||
@ -3705,14 +3704,13 @@ static int add_vlan_push_action(struct mlx5e_priv *priv,
|
||||
return -ENODEV;
|
||||
|
||||
if (is_vlan_dev(*out_dev))
|
||||
err = add_vlan_push_action(priv, attr, out_dev, action, extack);
|
||||
err = add_vlan_push_action(priv, attr, out_dev, extack);
|
||||
|
||||
return err;
|
||||
}
|
||||
|
||||
static int add_vlan_pop_action(struct mlx5e_priv *priv,
|
||||
struct mlx5_flow_attr *attr,
|
||||
u32 *action,
|
||||
struct netlink_ext_ack *extack)
|
||||
{
|
||||
struct flow_action_entry vlan_act = {
|
||||
@ -3723,7 +3721,8 @@ static int add_vlan_pop_action(struct mlx5e_priv *priv,
|
||||
nest_level = attr->parse_attr->filter_dev->lower_level -
|
||||
priv->netdev->lower_level;
|
||||
while (nest_level--) {
|
||||
err = parse_tc_vlan_action(priv, &vlan_act, attr->esw_attr, action, extack);
|
||||
err = parse_tc_vlan_action(priv, &vlan_act, attr->esw_attr,
|
||||
&attr->action, extack);
|
||||
if (err)
|
||||
return err;
|
||||
}
|
||||
@ -4093,16 +4092,13 @@ static int parse_tc_fdb_actions(struct mlx5e_priv *priv,
|
||||
return -ENODEV;
|
||||
|
||||
if (is_vlan_dev(out_dev)) {
|
||||
err = add_vlan_push_action(priv, attr,
|
||||
&out_dev,
|
||||
&attr->action, extack);
|
||||
err = add_vlan_push_action(priv, attr, &out_dev, extack);
|
||||
if (err)
|
||||
return err;
|
||||
}
|
||||
|
||||
if (is_vlan_dev(parse_attr->filter_dev)) {
|
||||
err = add_vlan_pop_action(priv, attr,
|
||||
&attr->action, extack);
|
||||
err = add_vlan_pop_action(priv, attr, extack);
|
||||
if (err)
|
||||
return err;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user