Re: [PATCH] crypto: omap - use min3 to simplify omap_crypto_copy_data
From: Herbert Xu
Date: Thu Jun 11 2026 - 01:40:47 EST
On Thu, Jun 04, 2026 at 02:10:36AM +0200, Thorsten Blum wrote:
> Replace two consecutive min() calls with min3() to simplify the code.
>
> Change the function parameters and local variables from int to size_t
> since these represent unsigned values and to prevent a signedness error.
>
> Signed-off-by: Thorsten Blum <thorsten.blum@xxxxxxxxx>
> ---
> drivers/crypto/omap-crypto.c | 12 ++++++------
> drivers/crypto/omap-crypto.h | 2 +-
> 2 files changed, 7 insertions(+), 7 deletions(-)
Please stop these min3 patches. It makes the code harder to read
for humans.
Thanks,
--
Email: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt