Re: [PATCH v2 01/20] s390/ap: Move response_type struct into ap_msg struct

Holger Dengler
2025-03-17T09:38:28Z

On 04/03/2025 18:20, Harald Freudenberger wrote:
> Move the very small response_type struct into struct ap_msg.
> So there is no need to kmalloc this tiny struct with each
> ap message preparation.
>
> Signed-off-by: Harald Freudenberger <freude@linux.ibm.com>

See my comment below. Beside that
Reviewed-by: Holger Dengler <dengler@linux.ibm.com>

> ---
> drivers/s390/crypto/ap_bus.h | 8 ++-
> drivers/s390/crypto/zcrypt_msgtype50.c | 16 ++----
> drivers/s390/crypto/zcrypt_msgtype6.c | 74 ++++++++++----------------
> 3 files changed, 38 insertions(+), 60 deletions(-)
[...]
> diff --git a/drivers/s390/crypto/zcrypt_msgtype6.c b/drivers/s390/crypto/zcrypt_msgtype6.c
> index b64c9d9fc613..521cc0b39990 100644
> --- a/drivers/s390/crypto/zcrypt_msgtype6.c
> +++ b/drivers/s390/crypto/zcrypt_msgtype6.c
> @@ -31,10 +31,7 @@
>
> #define CEIL4(x) ((((x) + 3) / 4) * 4)
>
> -struct response_type {
> - struct completion work;
> - int type;
> -};
> +struct response_type;

This struct is only defined, but not used. Remove it.

>
> #define CEXXC_RESPONSE_TYPE_ICA 0
> #define CEXXC_RESPONSE_TYPE_XCRB 1
[...]

--
Mit freundlichen Grüßen / Kind regards
Holger Dengler
--
IBM Systems, Linux on IBM Z Development
dengler@linux.ibm.com