diff options
author | Petr Machata <petrm@nvidia.com> | 2021-04-20 16:53:41 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2021-04-21 01:43:13 +0200 |
commit | 549f2aae84ddf574dda36b0bf7e3b4c0872c6675 (patch) | |
tree | 629efe42f8dec7eb3ea1f8a422d813c679a079d5 /drivers | |
parent | mlxsw: spectrum_qdisc: Simplify mlxsw_sp_qdisc_compare() (diff) | |
download | linux-549f2aae84ddf574dda36b0bf7e3b4c0872c6675.tar.xz linux-549f2aae84ddf574dda36b0bf7e3b4c0872c6675.zip |
mlxsw: spectrum_qdisc: Drop an always-true condition
The function mlxsw_sp_qdisc_compare() is invoked a couple lines above this
check, which will bounce any requests where this condition does not hold.
Therefore drop it.
Signed-off-by: Petr Machata <petrm@nvidia.com>
Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/ethernet/mellanox/mlxsw/spectrum_qdisc.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum_qdisc.c b/drivers/net/ethernet/mellanox/mlxsw/spectrum_qdisc.c index 013398ecd15b..f1d32bfc4bed 100644 --- a/drivers/net/ethernet/mellanox/mlxsw/spectrum_qdisc.c +++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum_qdisc.c @@ -886,10 +886,7 @@ int mlxsw_sp_setup_tc_fifo(struct mlxsw_sp_port *mlxsw_sp_port, switch (p->command) { case TC_FIFO_DESTROY: - if (p->handle == mlxsw_sp_qdisc->handle) - return mlxsw_sp_qdisc_destroy(mlxsw_sp_port, - mlxsw_sp_qdisc); - return 0; + return mlxsw_sp_qdisc_destroy(mlxsw_sp_port, mlxsw_sp_qdisc); case TC_FIFO_STATS: return mlxsw_sp_qdisc_get_stats(mlxsw_sp_port, mlxsw_sp_qdisc, &p->stats); |