RDMA/qedr: Fix potential use after free
authorPan Bian <bianpan2016@163.com>
Wed, 6 Nov 2019 06:23:54 +0000 (14:23 +0800)
committerJason Gunthorpe <jgg@mellanox.com>
Thu, 14 Nov 2019 15:47:18 +0000 (11:47 -0400)
commit960657b732e1ce21b07be5ab48a7ad3913d72ba4
tree6b0adb27c2b70b6ed23ba5d52bb5cd28277cbc8c
parente88982ad1bb12db699de96fbc07096359ef6176c
RDMA/qedr: Fix potential use after free

Move the release operation after error log to avoid possible use after
free.

Link: https://lore.kernel.org/r/1573021434-18768-1-git-send-email-bianpan2016@163.com
Signed-off-by: Pan Bian <bianpan2016@163.com>
Acked-by: Michal KalderonĀ <michal.kalderon@marvell.com>
Reviewed-by: Jason Gunthorpe <jgg@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/hw/qedr/qedr_iw_cm.c