Commit a1c6693a authored by Sagi Grimberg's avatar Sagi Grimberg Committed by David S. Miller

net/mlx4_en: Fix adaptive moderation cq update

When turning on adaptive_rx under adaptive moderation, the CQ's moderation
count wasn't updated according to rx_frames which resulted in too many
interrupts and bandwidth drop.
Signed-off-by: default avatarSagi Grimberg <sagig@mellanox.com>
Signed-off-by: default avatarAmir Vadai <amirv@mellanox.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 01cb71d2
...@@ -1323,6 +1323,7 @@ static void mlx4_en_auto_moderation(struct mlx4_en_priv *priv) ...@@ -1323,6 +1323,7 @@ static void mlx4_en_auto_moderation(struct mlx4_en_priv *priv)
priv->last_moder_time[ring] = moder_time; priv->last_moder_time[ring] = moder_time;
cq = &priv->rx_cq[ring]; cq = &priv->rx_cq[ring];
cq->moder_time = moder_time; cq->moder_time = moder_time;
cq->moder_cnt = priv->rx_frames;
err = mlx4_en_set_cq_moder(priv, cq); err = mlx4_en_set_cq_moder(priv, cq);
if (err) if (err)
en_err(priv, "Failed modifying moderation for cq:%d\n", en_err(priv, "Failed modifying moderation for cq:%d\n",
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment