Lines Matching refs:savp
102 sa_entry->savp, sa_entry->ifpo, sa_entry->kspi, bytes, packets); in mlx5e_ipsec_handle_counters()
157 struct secasvar *savp = sa_entry->savp; in mlx5e_ipsec_build_accel_xfrm_attrs() local
158 const struct auth_hash *esph = savp->tdb_authalgxform; in mlx5e_ipsec_build_accel_xfrm_attrs()
160 struct secasindex *saidx = &savp->sah->saidx; in mlx5e_ipsec_build_accel_xfrm_attrs()
161 struct seckey *key_encap = savp->key_enc; in mlx5e_ipsec_build_accel_xfrm_attrs()
167 key_len = _KEYLEN(key_encap) - SAV_ISCTRORGCM(savp) * 4 - SAV_ISCHACHA(savp) * 4; in mlx5e_ipsec_build_accel_xfrm_attrs()
177 switch (savp->alg_enc) { in mlx5e_ipsec_build_accel_xfrm_attrs()
195 attrs->spi = ntohl(savp->spi); in mlx5e_ipsec_build_accel_xfrm_attrs()
207 if (savp->natt) { in mlx5e_ipsec_build_accel_xfrm_attrs()
209 attrs->sport = savp->natt->sport; in mlx5e_ipsec_build_accel_xfrm_attrs()
210 attrs->dport = savp->natt->dport; in mlx5e_ipsec_build_accel_xfrm_attrs()
213 if (savp->flags & SADB_X_SAFLAGS_ESN) { in mlx5e_ipsec_build_accel_xfrm_attrs()
227 if (savp->replay) { in mlx5e_ipsec_build_accel_xfrm_attrs()
228 switch (savp->replay->wsize) { in mlx5e_ipsec_build_accel_xfrm_attrs()
250 struct secasvar *savp) in mlx5e_xfrm_validate_state() argument
252 struct secasindex *saidx = &savp->sah->saidx; in mlx5e_xfrm_validate_state()
253 struct seckey *key_encp = savp->key_enc; in mlx5e_xfrm_validate_state()
261 if (savp->state == SADB_SASTATE_DEAD) in mlx5e_xfrm_validate_state()
263 if (savp->alg_enc == SADB_EALG_NONE) { in mlx5e_xfrm_validate_state()
267 if (savp->alg_enc != SADB_X_EALG_AESGCM16) { in mlx5e_xfrm_validate_state()
271 if (savp->tdb_compalgxform) { in mlx5e_xfrm_validate_state()
275 if (savp->alg_auth != SADB_X_AALG_AES128GMAC && savp->alg_auth != SADB_X_AALG_AES256GMAC) { in mlx5e_xfrm_validate_state()
289 keylen = _KEYLEN(key_encp) - SAV_ISCTRORGCM(savp) * 4 - SAV_ISCHACHA(savp) * 4; in mlx5e_xfrm_validate_state()
300 if (savp->natt) { in mlx5e_xfrm_validate_state()
307 if (savp->replay && savp->replay->wsize != 0 && savp->replay->wsize != 4 && in mlx5e_xfrm_validate_state()
308 savp->replay->wsize != 8 && savp->replay->wsize != 16 && savp->replay->wsize != 32) { in mlx5e_xfrm_validate_state()
309 mlx5_core_err(mdev, "Unsupported replay window size %d\n", savp->replay->wsize); in mlx5e_xfrm_validate_state()
313 if ((savp->flags & SADB_X_SAFLAGS_ESN) != 0) { in mlx5e_xfrm_validate_state()
318 } else if (savp->replay != NULL && savp->replay->wsize != 0) { in mlx5e_xfrm_validate_state()
362 sa_entry->savp = sav; in mlx5e_if_sa_newkey_onedir()