From: Akhil Goyal <gak...@marvell.com>

Changed environment variable name for specifying
debug IV for unit testing of inline IPsec offload
with known test vectors.

Signed-off-by: Akhil Goyal <gak...@marvell.com>
---
 drivers/net/cnxk/cn10k_ethdev_sec.c | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/drivers/net/cnxk/cn10k_ethdev_sec.c 
b/drivers/net/cnxk/cn10k_ethdev_sec.c
index b307215..60b7093 100644
--- a/drivers/net/cnxk/cn10k_ethdev_sec.c
+++ b/drivers/net/cnxk/cn10k_ethdev_sec.c
@@ -522,10 +522,11 @@ cn10k_eth_sec_session_create(void *device,
                        goto mempool_put;
                }
 
-               iv_str = getenv("CN10K_ETH_SEC_IV_OVR");
-               if (iv_str)
-                       outb_dbg_iv_update(outb_sa_dptr, iv_str);
-
+               if (conf->ipsec.options.iv_gen_disable == 1) {
+                       iv_str = getenv("ETH_SEC_IV_OVR");
+                       if (iv_str)
+                               outb_dbg_iv_update(outb_sa_dptr, iv_str);
+               }
                /* Fill outbound sa misc params */
                rc = cn10k_eth_sec_outb_sa_misc_fill(&dev->nix, outb_sa_dptr,
                                                     outb_sa, ipsec, sa_idx);
-- 
2.8.4

Reply via email to