On Wed, Nov 08, 2017 at 01:54:03PM +0200, Gilad Ben-Yossef wrote: > > As a HW based crypto driver maintainer I sympathize, but let's play > devil's advocate for a second here: > > In the current state, HW based crypto drivers need to allocate a buffer > and copy the IV, because they don't know if they got a DMAable buffer > or not. SW based crypto drivers don't need to do anything. When I suggested an API change, I was thinking of an option of supplying an SG list instead of the current kernel pointer. IOW the existing users do not have to change but where we know that the pointer can be DMAed you can opt in to the new interface. The crypto API can then provide a helper to do the copying where necessary. Cheers, -- Email: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt