From: Gowrishankar Muthukrishnan <gmuthukri...@marvell.com>

Auth key length is stored as 8 bit value in SE context. It should
be larger enough to accommodate supported auth key length of 1024
bytes maximum, as in HMAC.

Fixes: a45859312ff ("common/cnxk: add SE definitions for symmetric crypto")

Signed-off-by: Gowrishankar Muthukrishnan <gmuthukri...@marvell.com>
---
 drivers/common/cnxk/roc_se.h | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/drivers/common/cnxk/roc_se.h b/drivers/common/cnxk/roc_se.h
index 6758142214..a0c97b26c5 100644
--- a/drivers/common/cnxk/roc_se.h
+++ b/drivers/common/cnxk/roc_se.h
@@ -288,16 +288,15 @@ struct roc_se_ctx {
        uint64_t enc_cipher : 8;
        uint64_t hash_type : 8;
        uint64_t mac_len : 8;
-       uint64_t auth_key_len : 8;
+       uint64_t auth_key_len : 16;
        uint64_t fc_type : 4;
        uint64_t hmac : 1;
        uint64_t zsk_flags : 3;
        uint64_t k_ecb : 1;
        uint64_t pdcp_ci_alg : 2;
        uint64_t pdcp_auth_alg : 2;
-       uint16_t ciph_then_auth : 1;
-       uint16_t auth_then_ciph : 1;
-       uint64_t rsvd : 17;
+       uint64_t ciph_then_auth : 1;
+       uint64_t auth_then_ciph : 1;
        union cpt_inst_w4 template_w4;
        /* Below fields are accessed by hardware */
        struct se_ctx_s {
-- 
2.25.1

Reply via email to