diff options
author | Victoria Milhoan <vicki.milhoan@freescale.com> | 2014-11-17 11:02:31 -0700 |
---|---|---|
committer | Nitin Garg <nitin.garg@nxp.com> | 2016-01-20 14:28:45 -0600 |
commit | e77b6c56b7bfdd472c3bf9a9e1c810ea262a62bc (patch) | |
tree | e25422b2c64bb4a3ac04443728ba5a96b92ec55e /drivers/crypto/caam | |
parent | 5e42172dcbda4be044f092e5943f5c3f94163ffa (diff) |
MLK-9769-21 Modify Freescale CAAM driver Scatter Gather entry definition
Modify the Scatter-Gather entry definitions for the Freescale
CAAM driver.
Signed-off-by: Victoria Milhoan <vicki.milhoan@freescale.com>
Signed-off-by: Dan Douglass <dan.douglass@freescale.com>
Diffstat (limited to 'drivers/crypto/caam')
-rw-r--r-- | drivers/crypto/caam/desc.h | 24 |
1 files changed, 20 insertions, 4 deletions
diff --git a/drivers/crypto/caam/desc.h b/drivers/crypto/caam/desc.h index ebdbf9e2742d..218d4d4ae389 100644 --- a/drivers/crypto/caam/desc.h +++ b/drivers/crypto/caam/desc.h @@ -8,13 +8,29 @@ #ifndef DESC_H #define DESC_H +/* + * 16-byte hardware scatter/gather table + * An 8-byte table exists in the hardware spec, but has never been + * implemented to date. The 8/16 option is selected at RTL-compile-time. + * and this selection is visible in the Compile Time Parameters Register + */ + +#define SEC4_SG_LEN_EXT 0x80000000 /* Entry points to table */ +#define SEC4_SG_LEN_FIN 0x40000000 /* Last ent in table */ +#define SEC4_SG_BPID_MASK 0x000000ff +#define SEC4_SG_BPID_SHIFT 16 +#define SEC4_SG_LEN_MASK 0x3fffffff /* Excludes EXT and FINAL */ +#define SEC4_SG_OFFS_MASK 0x00001fff + struct sec4_sg_entry { +#ifdef CONFIG_64BIT u64 ptr; -#define SEC4_SG_LEN_FIN 0x40000000 -#define SEC4_SG_LEN_EXT 0x80000000 +#else + u32 reserved; + u32 ptr; +#endif u32 len; - u8 reserved; - u8 buf_pool_id; + u16 buf_pool_id; u16 offset; }; |