mirror of
https://github.com/torvalds/linux.git
synced 2026-06-02 11:33:28 +02:00
mlxsw: spectrum_acl: Pass main driver structure to mlxsw_sp_acl_rulei_destroy()
The main driver structure will be needed in this function by a subsequent patch, so pass it. No functional changes intended. Signed-off-by: Ido Schimmel <idosch@nvidia.com> Reviewed-by: Petr Machata <petrm@nvidia.com> Signed-off-by: Petr Machata <petrm@nvidia.com> Link: https://lore.kernel.org/r/24d96a4e21310e5de2951ace58263db35e44a0df.1689092769.git.petrm@nvidia.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
d65f24c9fa
commit
898979c723
|
|
@ -994,7 +994,8 @@ void mlxsw_sp_acl_ruleset_prio_get(struct mlxsw_sp_acl_ruleset *ruleset,
|
|||
struct mlxsw_sp_acl_rule_info *
|
||||
mlxsw_sp_acl_rulei_create(struct mlxsw_sp_acl *acl,
|
||||
struct mlxsw_afa_block *afa_block);
|
||||
void mlxsw_sp_acl_rulei_destroy(struct mlxsw_sp_acl_rule_info *rulei);
|
||||
void mlxsw_sp_acl_rulei_destroy(struct mlxsw_sp *mlxsw_sp,
|
||||
struct mlxsw_sp_acl_rule_info *rulei);
|
||||
int mlxsw_sp_acl_rulei_commit(struct mlxsw_sp_acl_rule_info *rulei);
|
||||
void mlxsw_sp_acl_rulei_priority(struct mlxsw_sp_acl_rule_info *rulei,
|
||||
unsigned int priority);
|
||||
|
|
|
|||
|
|
@ -90,7 +90,7 @@ mlxsw_sp1_acl_ctcam_region_catchall_add(struct mlxsw_sp *mlxsw_sp,
|
|||
err_entry_add:
|
||||
err_rulei_commit:
|
||||
err_rulei_act_continue:
|
||||
mlxsw_sp_acl_rulei_destroy(rulei);
|
||||
mlxsw_sp_acl_rulei_destroy(mlxsw_sp, rulei);
|
||||
err_rulei_create:
|
||||
mlxsw_sp_acl_ctcam_chunk_fini(®ion->catchall.cchunk);
|
||||
return err;
|
||||
|
|
@ -105,7 +105,7 @@ mlxsw_sp1_acl_ctcam_region_catchall_del(struct mlxsw_sp *mlxsw_sp,
|
|||
mlxsw_sp_acl_ctcam_entry_del(mlxsw_sp, ®ion->cregion,
|
||||
®ion->catchall.cchunk,
|
||||
®ion->catchall.centry);
|
||||
mlxsw_sp_acl_rulei_destroy(rulei);
|
||||
mlxsw_sp_acl_rulei_destroy(mlxsw_sp, rulei);
|
||||
mlxsw_sp_acl_ctcam_chunk_fini(®ion->catchall.cchunk);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -339,7 +339,8 @@ mlxsw_sp_acl_rulei_create(struct mlxsw_sp_acl *acl,
|
|||
return ERR_PTR(err);
|
||||
}
|
||||
|
||||
void mlxsw_sp_acl_rulei_destroy(struct mlxsw_sp_acl_rule_info *rulei)
|
||||
void mlxsw_sp_acl_rulei_destroy(struct mlxsw_sp *mlxsw_sp,
|
||||
struct mlxsw_sp_acl_rule_info *rulei)
|
||||
{
|
||||
if (rulei->action_created)
|
||||
mlxsw_afa_block_destroy(rulei->act_block);
|
||||
|
|
@ -834,7 +835,7 @@ void mlxsw_sp_acl_rule_destroy(struct mlxsw_sp *mlxsw_sp,
|
|||
{
|
||||
struct mlxsw_sp_acl_ruleset *ruleset = rule->ruleset;
|
||||
|
||||
mlxsw_sp_acl_rulei_destroy(rule->rulei);
|
||||
mlxsw_sp_acl_rulei_destroy(mlxsw_sp, rule->rulei);
|
||||
kfree(rule);
|
||||
mlxsw_sp_acl_ruleset_ref_dec(mlxsw_sp, ruleset);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user