Re: [PATCH] crypto: atmel-tdes - simplify DMA buffer initialization
From: Herbert Xu
Date: Wed Sep 16 2026 - 09:21:16 EST
On Thu, Sep 03, 2026 at 11:08:46PM +0200, Thorsten Blum wrote:
> Calculate the buffer length in a single statement and simplify the error
> handling. Inline the dma_mapping_error() checks and return -ENOMEM from
> the common error path. If mapping the output buffer fails, unmap the
> previously mapped input buffer first.
>
> Also use dev_err() to log errors and %zu to format size_t, and clarify
> the error messages.
>
> Signed-off-by: Thorsten Blum <blum@xxxxxxxxxx>
> ---
> drivers/crypto/atmel-tdes.c | 36 ++++++++++++------------------------
> 1 file changed, 12 insertions(+), 24 deletions(-)
Patch applied. Thanks.
--
Email: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt