summaryrefslogtreecommitdiff
path: root/scripts/basic
diff options
context:
space:
mode:
authorHarald Freudenberger <freude@linux.ibm.com>2026-08-31 10:38:30 +0200
committerVasily Gorbik <gor@linux.ibm.com>2026-09-08 15:53:41 +0200
commit403648373816ae8eb76fe4a393836b0d65fa8f85 (patch)
tree2ab8ca394ca0259790535eca167f8ca18a7a8024 /scripts/basic
parentd1c44a7d085473173bb360b7218a43699c3f56c7 (diff)
downloadlinux-403648373816ae8eb76fe4a393836b0d65fa8f85.tar.gz
linux-403648373816ae8eb76fe4a393836b0d65fa8f85.zip
s390/crypto: Fix return code handling at skcipher_walk_done in PAES algorithms
All the 4 PAES cipher processing loops were not checking the return value of skcipher_walk_done() immediately after calling it. This could lead to error masking when both the walk operation failed and a subsequent key conversion was needed (k < n condition). Add immediate error checks after skcipher_walk_done() in all main processing loops (ECB, CBC, CTR, XTS modes) to ensure walk errors are properly propagated and not masked by subsequent operations. With that comes a slight rework around the skcipher_walk_done() invocation. It is now necessary to check if the walk has already been finalized (walk->nbytes is then 0) or not to avoid double de-allocation of resources held by the walk. Fixes: 6cd87cb5ef6c ("s390/crypto: Rework protected key AES for true asynch support") Signed-off-by: Harald Freudenberger <freude@linux.ibm.com> Reviewed-by: Holger Dengler <dengler@linux.ibm.com> Cc: stable@vger.kernel.org # 6.16+ Signed-off-by: Heiko Carstens <hca@linux.ibm.com> Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
Diffstat (limited to 'scripts/basic')
0 files changed, 0 insertions, 0 deletions