[PATCH] crypto: algboss: remove NULL check in cryptomgr_schedule_probe()

From: Roman Smirnov
Date: Wed Mar 06 2024 - 02:29:53 EST


The variable i will never be zero, so the check can be removed.

Found by Linux Verification Center (linuxtesting.org) with Svace.

Signed-off-by: Roman Smirnov <r.smirnov@xxxxxx>
Reviewed-by: Sergey Shtylyov <s.shtylyov@xxxxxx>
---
crypto/algboss.c | 3 ---
1 file changed, 3 deletions(-)

diff --git a/crypto/algboss.c b/crypto/algboss.c
index 0de1e6697949..1aa5f306998a 100644
--- a/crypto/algboss.c
+++ b/crypto/algboss.c
@@ -138,9 +138,6 @@ static int cryptomgr_schedule_probe(struct crypto_larval *larval)
goto err_free_param;
}

- if (!i)
- goto err_free_param;
-
param->tb[i + 1] = NULL;

param->type.attr.rta_len = sizeof(param->type);
--
2.34.1