]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-client.git/commit
s390/zcrypt: Fix memory leak with CCA cards used as accelerator
authorHarald Freudenberger <freude@linux.ibm.com>
Thu, 19 Mar 2026 08:06:52 +0000 (09:06 +0100)
committerVasily Gorbik <gor@linux.ibm.com>
Tue, 24 Mar 2026 19:57:31 +0000 (20:57 +0100)
commitc8d46f17c2fc7d25c18e60c008928aecab26184d
treeff785f85d923c5866d290c917720bbe63667b13f
parent57ad0d4a00f5d3e80f33ba2da8d560c73d83dc22
s390/zcrypt: Fix memory leak with CCA cards used as accelerator

Tests showed that there is a memory leak if CCA cards are used as
accelerator for clear key RSA requests (ME and CRT). With the last
rework for the memory allocation the AP messages are allocated by
ap_init_apmsg() but for some reason on two places (ME and CRT) the
older allocation was still in place. So the first allocation simple
was never freed.

Fixes: 57db62a130ce ("s390/ap/zcrypt: Rework AP message buffer allocation")
Reported-by: Yi Zhang <yi.zhang@redhat.com>
Closes: https://lore.kernel.org/linux-s390/CAHj4cs9H67Uz0iVaRQv447p7JFPRPy3TKAT4=Y6_e=wSHCZM5w@mail.gmail.com/
Reported-by: Nadja Hariz <Nadia.Hariz@ibm.com>
Cc: stable@vger.kernel.org
Reviewed-by: Ingo Franzki <ifranzki@linux.ibm.com>
Reviewed-by: Holger Dengler <dengler@linux.ibm.com>
Acked-by: Heiko Carstens <hca@linux.ibm.com>
Signed-off-by: Harald Freudenberger <freude@linux.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
drivers/s390/crypto/zcrypt_msgtype6.c