android_kernel_oneplus_msm8998/drivers/infiniband/hw
Wenwen Wang bc68ba54a2 IB/mlx4: Fix memory leaks
[ Upstream commit 5c1baaa82cea2c815a5180ded402a7cd455d1810 ]

In mlx4_ib_alloc_pv_bufs(), 'tun_qp->tx_ring' is allocated through
kcalloc(). However, it is not always deallocated in the following execution
if an error occurs, leading to memory leaks. To fix this issue, free
'tun_qp->tx_ring' whenever an error occurs.

Signed-off-by: Wenwen Wang <wenwen@cs.uga.edu>
Acked-by: Leon Romanovsky <leonro@mellanox.com>
Link: https://lore.kernel.org/r/1566159781-4642-1-git-send-email-wenwen@cs.uga.edu
Signed-off-by: Doug Ledford <dledford@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-09-10 10:29:48 +01:00
..
cxgb3 iw_cxgb3: Fix incorrectly returning error on success 2016-03-03 15:07:10 -08:00
cxgb4 RDMA/cxgb4: Fix null pointer dereference on alloc_skb failure 2019-06-11 12:23:59 +02:00
mlx4 IB/mlx4: Fix memory leaks 2019-09-10 10:29:48 +01:00
mlx5 IB/mlx5: Make coding style more consistent 2019-08-25 10:53:04 +02:00
mthca mm: replace get_user_pages() write/force parameters with gup_flags 2018-12-17 21:55:16 +01:00
nes Initial 4.4 merge window submission 2015-11-07 13:33:07 -08:00
ocrdma IB/ocrdma: fix out of bounds access to local buffer 2018-08-15 17:42:06 +02:00
qib IB/{hfi1, qib}: Fix WC.byte_len calculation for UD_SEND_WITH_IMM 2019-03-23 08:44:24 +01:00
usnic mm: replace get_user_pages() write/force parameters with gup_flags 2018-12-17 21:55:16 +01:00
Makefile IB/ehca: Deprecate driver, move to staging, schedule deletion 2015-09-11 18:13:35 -04:00