Commit a9efe54a authored by Mark Bloch's avatar Mark Bloch Committed by Zheng Zengkai
Browse files

RDMA/mlx5: Fix wrong free of blue flame register on error

stable inclusion
from stable-5.10.9
commit bc296e43233ab8ac2250dcc8c9aa62baed54742f
bugzilla: 47457

--------------------------------

commit 1c3aa6bd upstream.

If the allocation of the fast path blue flame register fails, the driver
should free the regular blue flame register allocated a statement above,
not the one that it just failed to allocate.

Fixes: 16c1975f ("IB/mlx5: Create profile infrastructure to add and remove stages")
Link: https://lore.kernel.org/r/20210113121703.559778-6-leon@kernel.org


Reported-by: default avatarHans Petter Selasky <hanss@nvidia.com>
Signed-off-by: default avatarMark Bloch <mbloch@nvidia.com>
Signed-off-by: default avatarLeon Romanovsky <leonro@nvidia.com>
Signed-off-by: default avatarJason Gunthorpe <jgg@nvidia.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>

Signed-off-by: default avatarChen Jun <chenjun102@huawei.com>
Acked-by: default avatarXie XiuQi <xiexiuqi@huawei.com>
parent 1cd6200e
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment