[SRU][F:linux-bluefield][PATCH 1/1] pka: Fix NULL pointer kfree() issue
Mahantesh Salimath
mahantesh at nvidia.com
Thu Jun 10 14:48:51 UTC 2021
BugLink: https://bugs.launchpad.net/bugs/1931584
Signed-off-by: Mahantesh Salimath <mahantesh at nvidia.com>
Reviewed-by: Khalil Blaiech <kblaiech at nvidia.com>
Signed-off-by: Mahantesh Salimath <mahantesh at nvidia.com>
---
diff --git a/drivers/platform/mellanox/mlxbf_pka/mlxbf_pka_dev.c b/drivers/platform/mellanox/mlxbf_pka/mlxbf_pka_dev.c
--- a/drivers/platform/mellanox/mlxbf_pka/mlxbf_pka_dev.c
+++ b/drivers/platform/mellanox/mlxbf_pka/mlxbf_pka_dev.c
@@ -707,7 +707,6 @@ static int pka_dev_create_shim(pka_dev_shim_t *shim, uint32_t shim_id,
if (!shim->rings)
{
PKA_ERROR(PKA_DEV, "unable to kmalloc\n");
- kfree(shim->rings);
return -ENOMEM;
}
--
2.30.1
More information about the kernel-team
mailing list