crypto: inside-secure - Base CD fetchcount on actual CD FIFO size
This patch derives the command descriptor fetch count from the actual FIFO size advertised by the hardware. Fetching command descriptors one at a time is a performance bottleneck for small blocks, especially on hardware with multiple pipes. Even moreso if the HW has few rings. Signed-off-by: Pascal van Leeuwen <pvanleeuwen@verimatrix.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
This commit is contained in:

committed by
Herbert Xu

parent
4bdf712c30
commit
35c0e6c375
@@ -31,6 +31,7 @@
|
||||
#define EIP197_MAX_TOKENS 18
|
||||
#define EIP197_MAX_RINGS 4
|
||||
#define EIP197_FETCH_COUNT 1
|
||||
#define EIP197_FETCH_DEPTH 2
|
||||
#define EIP197_MAX_BATCH_SZ 64
|
||||
|
||||
#define EIP197_GFP_FLAGS(base) ((base).flags & CRYPTO_TFM_REQ_MAY_SLEEP ? \
|
||||
@@ -225,6 +226,14 @@
|
||||
#define EIP197_N_PES_OFFSET 4
|
||||
#define EIP197_N_PES_MASK GENMASK(4, 0)
|
||||
#define EIP97_N_PES_MASK GENMASK(2, 0)
|
||||
#define EIP197_HWDATAW_OFFSET 25
|
||||
#define EIP197_HWDATAW_MASK GENMASK(3, 0)
|
||||
#define EIP97_HWDATAW_MASK GENMASK(2, 0)
|
||||
#define EIP197_CFSIZE_OFFSET 9
|
||||
#define EIP197_CFSIZE_ADJUST 4
|
||||
#define EIP97_CFSIZE_OFFSET 8
|
||||
#define EIP197_CFSIZE_MASK GENMASK(3, 0)
|
||||
#define EIP97_CFSIZE_MASK GENMASK(4, 0)
|
||||
|
||||
/* EIP197_HIA_AIC_R_ENABLE_CTRL */
|
||||
#define EIP197_CDR_IRQ(n) BIT((n) * 2)
|
||||
@@ -680,6 +689,8 @@ struct safexcel_hwconfig {
|
||||
int hwver;
|
||||
int hiaver;
|
||||
int pever;
|
||||
int hwdataw;
|
||||
int hwcfsize;
|
||||
};
|
||||
|
||||
struct safexcel_crypto_priv {
|
||||
|
Reference in New Issue
Block a user