We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3e41105 commit f79edefCopy full SHA for f79edef
drivers/infiniband/hw/mana/cq.c
@@ -70,6 +70,8 @@ int mana_ib_install_cq_cb(struct mana_ib_dev *mdev, struct mana_ib_cq *cq)
70
struct gdma_context *gc = mdev_to_gc(mdev);
71
struct gdma_queue *gdma_cq;
72
73
+ if (cq->queue.id >= gc->max_num_cqs)
74
+ return -EINVAL;
75
/* Create CQ table entry */
76
WARN_ON(gc->cq_table[cq->queue.id]);
77
gdma_cq = kzalloc(sizeof(*gdma_cq), GFP_KERNEL);
0 commit comments