]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
crypto: iaa - Fix incorrect return value in save_iaa_wq()
authorZilin Guan <zilin@seu.edu.cn>
Sun, 9 Nov 2025 14:56:48 +0000 (14:56 +0000)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 14 Nov 2025 10:15:49 +0000 (18:15 +0800)
The save_iaa_wq() function unconditionally returns 0, even when an error
is encountered. This prevents the error code from being propagated to the
caller.

Fix this by returning the 'ret' variable, which holds the actual status
of the operations within the function.

Fixes: ea7a5cbb43696 ("crypto: iaa - Add Intel IAA Compression Accelerator crypto driver core")
Signed-off-by: Zilin Guan <zilin@seu.edu.cn>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/intel/iaa/iaa_crypto_main.c

index 23f585219fb4b2c6777d51036baf19012901eb70..d0058757b0000d2e7cd9d6bc15416a8319ee83cb 100644 (file)
@@ -805,7 +805,7 @@ static int save_iaa_wq(struct idxd_wq *wq)
        if (!cpus_per_iaa)
                cpus_per_iaa = 1;
 out:
-       return 0;
+       return ret;
 }
 
 static void remove_iaa_wq(struct idxd_wq *wq)