Re: crypto_shash_update & CRYPTO_TFM_REQ_MAY_SLEEP

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

How is it possible to wait for completion here?: shash.c

shash_compat_digest()
{
....
        data = crypto_kmap(sg_page(sg), 0);
        err = crypto_shash_digest(desc, data + offset, nbytes, out);
        crypto_kunmap(data, 0);
....
}

It happens as single operation/call.

Thanks,
Dmitry


ext Herbert Xu wrote:
> On Tue, Feb 16, 2010 at 08:36:08AM +0200, Dmitry Kasatkin wrote:
>   
>> Hi,
>>
>> we have HW accelerator which can be accessed without DMA.
>> CPU just sequentially writes data to the port and then reads result.
>>     
>
> Well if that's the case then you definitely don't need anything
> other than kmap_atomic.  You should be able to map it atomically,
> write the data out, unmap it, and then wait for the completion.
>
> Non-atomic kmaps should be avoided if at all possible.
>
> Cheers,
>   
--
To unsubscribe from this list: send the line "unsubscribe linux-crypto" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel]     [Gnu Classpath]     [Gnu Crypto]     [DM Crypt]     [Netfilter]     [Bugtraq]

  Powered by Linux