Refactor mlx5_create_auto_grouped_flow_table() to use ft_attr param which already carries the max_fte, prio and flags memebers, and is used the same in similar mlx5_create_flow_table() function.
Showing the changes to include/linux (1 of 8 files). Show all
Unified · Split
| @@ -145,25 +145,25 @@ mlx5_get_flow_vport_acl_namespace(struct mlx5_core_dev *dev, · 144 unmodified lines | ||
| 145 | 145 | enum mlx5_flow_namespace_type type, |
| 146 | 146 | int vport); |
| 147 | 147 | |
| 148 | −struct mlx5_flow_table * | |
| 149 | −mlx5_create_auto_grouped_flow_table(struct mlx5_flow_namespace *ns, | |
| 150 | − int prio, | |
| 151 | − int num_flow_table_entries, | |
| 152 | − int max_num_groups, | |
| 153 | − u32 level, | |
| 154 | − u32 flags); | |
| 155 | − | |
| 156 | 148 | struct mlx5_flow_table_attr { |
| 157 | 149 | int prio; |
| 158 | 150 | int max_fte; |
| 159 | 151 | u32 level; |
| 160 | 152 | u32 flags; |
| 153 | + | |
| 154 | + struct { | |
| 155 | + int max_num_groups; | |
| 156 | + } autogroup; | |
| 161 | 157 | }; |
| 162 | 158 | |
| 163 | 159 | struct mlx5_flow_table * |
| 164 | 160 | mlx5_create_flow_table(struct mlx5_flow_namespace *ns, |
| 165 | 161 | struct mlx5_flow_table_attr *ft_attr); |
| 166 | 162 | |
| 163 | +struct mlx5_flow_table * | |
| 164 | +mlx5_create_auto_grouped_flow_table(struct mlx5_flow_namespace *ns, | |
| 165 | + struct mlx5_flow_table_attr *ft_attr); | |
| 166 | + | |
| 167 | 167 | struct mlx5_flow_table * |
| 168 | 168 | mlx5_create_vport_flow_table(struct mlx5_flow_namespace *ns, |
| 169 | 169 | int prio, |