forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-01-05 071106ecf68c401173c58808b1cf5f68cc50d390
kernel/drivers/net/ethernet/mellanox/mlx4/en_cq.c
....@@ -54,11 +54,8 @@
5454
5555 cq = kzalloc_node(sizeof(*cq), GFP_KERNEL, node);
5656 if (!cq) {
57
- cq = kzalloc(sizeof(*cq), GFP_KERNEL);
58
- if (!cq) {
59
- en_err(priv, "Failed to allocate CQ structure\n");
60
- return -ENOMEM;
61
- }
57
+ en_err(priv, "Failed to allocate CQ structure\n");
58
+ return -ENOMEM;
6259 }
6360
6461 cq->size = entries;
....@@ -143,7 +140,7 @@
143140 cq->mcq.usage = MLX4_RES_USAGE_DRIVER;
144141 err = mlx4_cq_alloc(mdev->dev, cq->size, &cq->wqres.mtt,
145142 &mdev->priv_uar, cq->wqres.db.dma, &cq->mcq,
146
- cq->vector, 0, timestamp_en);
143
+ cq->vector, 0, timestamp_en, &cq->wqres.buf, false);
147144 if (err)
148145 goto free_eq;
149146