X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=examples%2Fipsec-secgw%2Fesp.c;h=ead4071efa1451e5b15d52eee872bd6623ab179b;hb=0fbd75a99fc9;hp=387ce4f8c19fd88075afda90bfcaf5ccf9c9d1b2;hpb=5082f991f6def0ef06e9ff1cf9f39ef3b78657c5;p=dpdk.git diff --git a/examples/ipsec-secgw/esp.c b/examples/ipsec-secgw/esp.c index 387ce4f8c1..ead4071efa 100644 --- a/examples/ipsec-secgw/esp.c +++ b/examples/ipsec-secgw/esp.c @@ -50,9 +50,6 @@ #include "esp.h" #include "ipip.h" -#define IV_OFFSET (sizeof(struct rte_crypto_op) + \ - sizeof(struct rte_crypto_sym_op)) - int esp_inbound(struct rte_mbuf *m, struct ipsec_sa *sa, struct rte_crypto_op *cop) @@ -104,8 +101,6 @@ esp_inbound(struct rte_mbuf *m, struct ipsec_sa *sa, case RTE_CRYPTO_CIPHER_AES_CBC: /* Copy IV at the end of crypto operation */ rte_memcpy(iv_ptr, iv, sa->iv_len); - sym_cop->cipher.iv.offset = IV_OFFSET; - sym_cop->cipher.iv.length = sa->iv_len; break; case RTE_CRYPTO_CIPHER_AES_CTR: case RTE_CRYPTO_CIPHER_AES_GCM: @@ -113,8 +108,6 @@ esp_inbound(struct rte_mbuf *m, struct ipsec_sa *sa, icb->salt = sa->salt; memcpy(&icb->iv, iv, 8); icb->cnt = rte_cpu_to_be_32(1); - sym_cop->cipher.iv.offset = IV_OFFSET; - sym_cop->cipher.iv.length = 16; break; default: RTE_LOG(ERR, IPSEC_ESP, "unsupported cipher algorithm %u\n", @@ -348,8 +341,6 @@ esp_outbound(struct rte_mbuf *m, struct ipsec_sa *sa, icb->salt = sa->salt; icb->iv = sa->seq; icb->cnt = rte_cpu_to_be_32(1); - sym_cop->cipher.iv.offset = IV_OFFSET; - sym_cop->cipher.iv.length = 16; uint8_t *aad;