]> git.baikalelectronics.ru Git - kernel.git/commit
RDMA/nes: Avoid memory allocation during CQ destroy
authorLeon Romanovsky <leonro@mellanox.com>
Tue, 28 May 2019 11:37:27 +0000 (14:37 +0300)
committerDoug Ledford <dledford@redhat.com>
Tue, 11 Jun 2019 20:12:34 +0000 (16:12 -0400)
commitd41f8fc97770cbdc559b7d76cdb9d43b2c0cef1e
tree4eb3502ef1d3e856e82d8449c5db7e5a2f7732c5
parentc38e4f7537e7936c6bf44a4256931c61cb6286a4
RDMA/nes: Avoid memory allocation during CQ destroy

The memory allocation call can fail and cause to early return
from nes_desotroy_cq() function. This situation will cause to
memory leak of struct nes_cq. Rewrite function to avoid memory
allocation.

Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/nes/nes_verbs.c