Re: [PATCH] crypto: safexcel - Unwind SHA3 initialization if HMAC setup fails

From: Krzysztof Kozlowski

Date: Tue Nov 03 2026 - 02:10:56 EST


On 03/11/2026 07:40, Wentao Liang wrote:
> safexcel_hmac_sha3_cra_init() first initializes the SHA3 context, which
> allocates an ahash fallback. If allocating the shash transform or its
> descriptor fails afterwards, that fallback is not released. The crypto
> core does not invoke cra_exit after cra_init returns an error.
>
> Call safexcel_sha3_cra_exit() on these failure paths to release the
> resources acquired by safexcel_sha3_cra_init().
>
> Fixes: 6c1c09b3dd0c ("crypto: inside-secure - Add HMAC-SHA3 family of authentication algorithms")
> Cc: stable@xxxxxxxxxxxxxxx
> Assisted-by: DeepSeek-V4.1-Flash and OpenAI Codex

Not even bothering to run checkpatch.

> Signed-off-by: Wentao Liang <vulab@xxxxxxxxxxx>

Another fake identity of "vulab" doing exactly the same as other cases,
repeating same mistake of running unsupervised crappy bot even though
was asked multiple times to fix that.

Best regards,
Krzysztof