]> git.baikalelectronics.ru Git - kernel.git/commit
RDMA/hns: Prevent memory leaks of eq->buf_list
authorLijun Ou <oulijun@huawei.com>
Sat, 26 Oct 2019 06:56:35 +0000 (14:56 +0800)
committerJason Gunthorpe <jgg@mellanox.com>
Mon, 28 Oct 2019 18:06:38 +0000 (15:06 -0300)
commit6feb4eee7b0644ee02f18c6fc89357a8cb3540e9
tree08d2cc07c46e1d047a8afa6be7e7a85eda00a7ec
parent3d8c469c71ea497a1bce73acf5bf4d06efdc53f8
RDMA/hns: Prevent memory leaks of eq->buf_list

eq->buf_list->buf and eq->buf_list should also be freed when eqe_hop_num
is set to 0, or there will be memory leaks.

Fixes: c55e5c868a98 ("RDMA/hns: Add eq support of hip08")
Link: https://lore.kernel.org/r/1572072995-11277-3-git-send-email-liweihang@hisilicon.com
Signed-off-by: Lijun Ou <oulijun@huawei.com>
Signed-off-by: Weihang Li <liweihang@hisilicon.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/hw/hns/hns_roce_hw_v2.c