[PATCH] crypto: talitos - Remove GFP_DMA and add DMA alignment padding

Herbert Xu herbert at gondor.apana.org.au
Sun Jan 8 23:37:33 PST 2023


On Mon, Jan 09, 2023 at 07:18:27AM +0000, Christophe Leroy wrote:
>
> Doesn't GFP_DMA guarantees that the provided memory is addressable for 
> DMA ? Or do we assume that all memory returned by kmalloc can be used 
> for DMA ?

No it does not.  Please refer to the DMI API documentation.

> kmalloc() already returns not DMA aligned memory, why does it becomes a 
> problem now ?

As it stands kmalloc on arm64 returns DMA-aligned memory.  This
will soon no longer be the case.

Cheers,
-- 
Email: Herbert Xu <herbert at gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt



More information about the linux-arm-kernel mailing list