Commit 5a212e0c authored by Li RongQing's avatar Li RongQing Committed by Saeed Mahameed

net/mlx5: rate limit alloc_ent error messages

when debug a bug, which triggers TX hang, and kernel log is
spammed with the following info message

    [ 1172.044764] mlx5_core 0000:21:00.0: cmd_work_handler:930:(pid 8):
    failed to allocate command entry
Signed-off-by: default avatarLi RongQing <lirongqing@baidu.com>
Signed-off-by: default avatarSaeed Mahameed <saeedm@mellanox.com>
parent ab9341b5
...@@ -866,7 +866,7 @@ static void cmd_work_handler(struct work_struct *work) ...@@ -866,7 +866,7 @@ static void cmd_work_handler(struct work_struct *work)
if (!ent->page_queue) { if (!ent->page_queue) {
alloc_ret = alloc_ent(cmd); alloc_ret = alloc_ent(cmd);
if (alloc_ret < 0) { if (alloc_ret < 0) {
mlx5_core_err(dev, "failed to allocate command entry\n"); mlx5_core_err_rl(dev, "failed to allocate command entry\n");
if (ent->callback) { if (ent->callback) {
ent->callback(-EAGAIN, ent->context); ent->callback(-EAGAIN, ent->context);
mlx5_free_cmd_msg(dev, ent->out); mlx5_free_cmd_msg(dev, ent->out);
......
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