diff options
author | Jiri Pirko <jiri@mellanox.com> | 2019-03-31 06:49:39 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-03-31 11:01:23 -0700 |
commit | f3d4ef1a533a0521c73e343f8191b23702fe8ad6 (patch) | |
tree | 4ca303e246a5d180ad3f7336fe8b3803f80ebffa /drivers/net/ethernet | |
parent | 44fd86cb7e6d01f32a0db1e6ba25272dcf5dc9f4 (diff) | |
download | linux-f3d4ef1a533a0521c73e343f8191b23702fe8ad6.tar.bz2 |
mlxsw: spectrum_acl: Move rehash_dis trace call and err msg to vregion_migrate()
Move the call of rehash_dis trace and the error message to
vregion_migrate() next to the failed_rollback flag set.
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet')
-rw-r--r-- | drivers/net/ethernet/mellanox/mlxsw/spectrum_acl_tcam.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum_acl_tcam.c b/drivers/net/ethernet/mellanox/mlxsw/spectrum_acl_tcam.c index a26854f97f0f..a2af385bcd63 100644 --- a/drivers/net/ethernet/mellanox/mlxsw/spectrum_acl_tcam.c +++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum_acl_tcam.c @@ -1394,8 +1394,12 @@ mlxsw_sp_acl_tcam_vregion_migrate(struct mlxsw_sp *mlxsw_sp, ctx->this_is_rollback = true; err2 = mlxsw_sp_acl_tcam_vchunk_migrate_all(mlxsw_sp, vregion, ctx, credits); - if (err2) + if (err2) { vregion->failed_rollback = true; + trace_mlxsw_sp_acl_tcam_vregion_rehash_dis(mlxsw_sp, + vregion); + dev_err(mlxsw_sp->bus_info->dev, "Failed to rollback during vregion migration fail\n"); + } } mutex_unlock(&vregion->lock); trace_mlxsw_sp_acl_tcam_vregion_migrate_end(mlxsw_sp, vregion); @@ -1503,11 +1507,6 @@ mlxsw_sp_acl_tcam_vregion_rehash(struct mlxsw_sp *mlxsw_sp, ctx, credits); if (err) { dev_err(mlxsw_sp->bus_info->dev, "Failed to migrate vregion\n"); - if (vregion->failed_rollback) { - trace_mlxsw_sp_acl_tcam_vregion_rehash_dis(mlxsw_sp, - vregion); - dev_err(mlxsw_sp->bus_info->dev, "Failed to rollback during vregion migration fail\n"); - } } if (*credits >= 0) |