]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
s390/ap/zcrypt: Rework AP message buffer allocation
authorHarald Freudenberger <freude@linux.ibm.com>
Thu, 24 Apr 2025 13:35:56 +0000 (15:35 +0200)
committerHeiko Carstens <hca@linux.ibm.com>
Wed, 30 Apr 2025 09:34:00 +0000 (11:34 +0200)
commit57db62a130ce69e6f3a870cf1119d8f860391f97
tree31944e1e961e7773d7dd24a0abc2e986790dbf19
parent43435495a0f4e3a08792835285901b01e6d5b6da
s390/ap/zcrypt: Rework AP message buffer allocation

Slight rework on the way how AP message buffers are allocated.
Instead of having multiple places with kmalloc() calls all
the AP message buffers are now allocated and freed on exactly
one place: ap_init_apmsg() allocates the current AP bus max
limit of ap_max_msg_size (defaults to 12KB). The AP message
buffer is then freed in ap_release_apmsg().

Signed-off-by: Harald Freudenberger <freude@linux.ibm.com>
Reviewed-by: Holger Dengler <dengler@linux.ibm.com>
Link: https://lore.kernel.org/r/20250424133619.16495-3-freude@linux.ibm.com
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
drivers/s390/crypto/ap_bus.c
drivers/s390/crypto/ap_bus.h
drivers/s390/crypto/zcrypt_api.c
drivers/s390/crypto/zcrypt_msgtype50.c
drivers/s390/crypto/zcrypt_msgtype6.c