[PATCHv2 06/27] crypto: ahash: increase the maximum allowed statesize
Tero Kristo
t-kristo at ti.com
Mon Jul 4 02:27:00 PDT 2016
On 04/07/16 12:19, Herbert Xu wrote:
> On Mon, Jul 04, 2016 at 12:17:02PM +0300, Tero Kristo wrote:
>>
>> I need some clarification on this, afaik request_alloc related
>> functionality only works per-request basis. The export / import
>> functionality however is supposed to work across multiple requests.
>> The test code for example does this:
>
> Why are you trying to allocate memory in export/import at all?
> The preferred approach is to unconditionally allocate the memory
> in ahash_request_alloc.
The driver allocates a largish buffer for copying the input data from
the sgs into a sequential space. If I don't save the contents of this
buffer anywhere, the export/import doesn't work as expected it seems.
Actually I am now wondering why the driver allocates this sequential
buffer at all, DMA should be possible to use over the sgs just fine, at
least some other crypto drivers are doing this.
-Tero
More information about the linux-arm-kernel
mailing list