From e29d566efb31378fbeac61f0b1a7dbd690d7e287 Mon Sep 17 00:00:00 2001 From: Ze Gan Date: Fri, 7 May 2021 09:48:58 +0800 Subject: [PATCH] [orchagent]: Update MACsec SAI API to 1.8.0 and re-enable MACsec test (#1733) Signed-off-by: Ze Gan --- orchagent/macsecorch.cpp | 4 ++-- tests/test_macsec.py | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/orchagent/macsecorch.cpp b/orchagent/macsecorch.cpp index a03a6807cd37..86cd3c355b49 100644 --- a/orchagent/macsecorch.cpp +++ b/orchagent/macsecorch.cpp @@ -1848,13 +1848,13 @@ bool MACsecOrch::createMACsecSA( if (direction == SAI_MACSEC_DIRECTION_EGRESS) { - attr.id = SAI_MACSEC_SA_ATTR_XPN; + attr.id = SAI_MACSEC_SA_ATTR_CONFIGURED_EGRESS_XPN; attr.value.u64 = pn; attrs.push_back(attr); } else { - attr.id = SAI_MACSEC_SA_ATTR_MINIMUM_XPN; + attr.id = SAI_MACSEC_SA_ATTR_MINIMUM_INGRESS_XPN; attr.value.u64 = pn; attrs.push_back(attr); } diff --git a/tests/test_macsec.py b/tests/test_macsec.py index 249dad0c9287..96716c65adc7 100644 --- a/tests/test_macsec.py +++ b/tests/test_macsec.py @@ -2,7 +2,6 @@ import conftest import sys -import pytest import functools import typing import re @@ -588,7 +587,6 @@ def deinit_macsec( macsec_port_identifier)) wpa.deinit_macsec_port(port_name) - @pytest.mark.skip("Skip to be removed after macsec orch is made compatible to SAI v1.8.0") def test_macsec_term_orch(self, dvs: conftest.DockerVirtualSwitch, testlog): port_name = "Ethernet0" local_mac_address = "00-15-5D-78-FF-C1"