lkml.org 
[lkml]   [2014]   [Jan]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH RFC 1/2] crypto: Simple crypto algorithm load balancer
On Sat, Jan 18, 2014 at 12:46:08AM +0000, Tadeusz Struk wrote:
> Hi,
> In case of multiple crypto devices implementing the same algorithms
> the arbitration, which one to use is based on the cra_priority.
> Currently the algorithm with the highest priority is always be used.
> In case of two algorithms with the same priority the one added last is used.
> There is no load balancing and on a busy system there can be a situation when
> there more crypto accelerators, but only one is used for all crypto jobs
> and the others sit idle.
> This patch implements a simple load balancing based on the priority
> of an algorithm and its usage refctr. The distribution for 10 algorithms
> and 3000000 tfm_alloc allocations is as follows:

Have you looked at pcrypt and whether it can be extended to handle
this or perhaps something similar to pcrypt can be created?

Hard-coding this into the API seems a bit heavy-handed.

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


\
 
 \ /
  Last update: 2014-01-18 13:21    [W:0.038 / U:0.068 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site