diff mbox series

[ovs-dev] system-traffic: Fix conntrack per zone limit test.

Message ID 1536239920-76330-1-git-send-email-tiago.lam@intel.com
State Accepted
Headers show
Series [ovs-dev] system-traffic: Fix conntrack per zone limit test. | expand

Commit Message

Lam, Tiago Sept. 6, 2018, 1:18 p.m. UTC
Commit 3f1087c added a per zone limit test which relied on the
CHECK_CT_DPIF_FLUSH_BY_CT_TUPLE m4 macro to skip the test when executing
in a userspace datapath (since the per zone limit feature is not yet
implemented in userspace). That macro, however, has been removed in
commit 271e48a ("conntrack: Support conntrack flush by ct 5-tuple")
which was causing the test to fail when executing in userspace.

Instead, a new m4 macro, CHECK_CT_DPIF_PER_ZONE_LIMIT, is introduced to
make the same differentiation, until userspace doesn't support the per
zone limit.

CC: Yi-Hung Wei <yihung.wei@gmail.com>
Fixes: 3f1087c ("system-traffic: Add conntrack per zone limit test case")
Signed-off-by: Tiago Lam <tiago.lam@intel.com>
---
 tests/system-kmod-macros.at      | 7 +++++++
 tests/system-traffic.at          | 2 +-
 tests/system-userspace-macros.at | 9 +++++++++
 3 files changed, 17 insertions(+), 1 deletion(-)

Comments

Yi-Hung Wei Sept. 6, 2018, 4:56 p.m. UTC | #1
On Thu, Sep 6, 2018 at 6:18 AM Tiago Lam <tiago.lam@intel.com> wrote:
>
> Commit 3f1087c added a per zone limit test which relied on the
> CHECK_CT_DPIF_FLUSH_BY_CT_TUPLE m4 macro to skip the test when executing
> in a userspace datapath (since the per zone limit feature is not yet
> implemented in userspace). That macro, however, has been removed in
> commit 271e48a ("conntrack: Support conntrack flush by ct 5-tuple")
> which was causing the test to fail when executing in userspace.
>
> Instead, a new m4 macro, CHECK_CT_DPIF_PER_ZONE_LIMIT, is introduced to
> make the same differentiation, until userspace doesn't support the per
> zone limit.
>
> CC: Yi-Hung Wei <yihung.wei@gmail.com>
> Fixes: 3f1087c ("system-traffic: Add conntrack per zone limit test case")
> Signed-off-by: Tiago Lam <tiago.lam@intel.com>
> ---
Thanks Tiago for the fix. I will work on the userspace zone limitation later on.

Acked-by: Yi-Hung Wei <yihung.wei@gmail.com>
Ben Pfaff Sept. 6, 2018, 11:07 p.m. UTC | #2
On Thu, Sep 06, 2018 at 09:56:26AM -0700, Yi-Hung Wei wrote:
> On Thu, Sep 6, 2018 at 6:18 AM Tiago Lam <tiago.lam@intel.com> wrote:
> >
> > Commit 3f1087c added a per zone limit test which relied on the
> > CHECK_CT_DPIF_FLUSH_BY_CT_TUPLE m4 macro to skip the test when executing
> > in a userspace datapath (since the per zone limit feature is not yet
> > implemented in userspace). That macro, however, has been removed in
> > commit 271e48a ("conntrack: Support conntrack flush by ct 5-tuple")
> > which was causing the test to fail when executing in userspace.
> >
> > Instead, a new m4 macro, CHECK_CT_DPIF_PER_ZONE_LIMIT, is introduced to
> > make the same differentiation, until userspace doesn't support the per
> > zone limit.
> >
> > CC: Yi-Hung Wei <yihung.wei@gmail.com>
> > Fixes: 3f1087c ("system-traffic: Add conntrack per zone limit test case")
> > Signed-off-by: Tiago Lam <tiago.lam@intel.com>
> > ---
> Thanks Tiago for the fix. I will work on the userspace zone limitation later on.
> 
> Acked-by: Yi-Hung Wei <yihung.wei@gmail.com>

Thanks Tiago and Yi-Hung.  I applied this to master.  Let me know if I
should backport it.
Yi-Hung Wei Sept. 6, 2018, 11:19 p.m. UTC | #3
On Thu, Sep 6, 2018 at 4:07 PM Ben Pfaff <blp@ovn.org> wrote:
>
> On Thu, Sep 06, 2018 at 09:56:26AM -0700, Yi-Hung Wei wrote:
> > On Thu, Sep 6, 2018 at 6:18 AM Tiago Lam <tiago.lam@intel.com> wrote:
> > >
> > > Commit 3f1087c added a per zone limit test which relied on the
> > > CHECK_CT_DPIF_FLUSH_BY_CT_TUPLE m4 macro to skip the test when executing
> > > in a userspace datapath (since the per zone limit feature is not yet
> > > implemented in userspace). That macro, however, has been removed in
> > > commit 271e48a ("conntrack: Support conntrack flush by ct 5-tuple")
> > > which was causing the test to fail when executing in userspace.
> > >
> > > Instead, a new m4 macro, CHECK_CT_DPIF_PER_ZONE_LIMIT, is introduced to
> > > make the same differentiation, until userspace doesn't support the per
> > > zone limit.
> > >
> > > CC: Yi-Hung Wei <yihung.wei@gmail.com>
> > > Fixes: 3f1087c ("system-traffic: Add conntrack per zone limit test case")
> > > Signed-off-by: Tiago Lam <tiago.lam@intel.com>
> > > ---
> > Thanks Tiago for the fix. I will work on the userspace zone limitation later on.
> >
> > Acked-by: Yi-Hung Wei <yihung.wei@gmail.com>
>
> Thanks Tiago and Yi-Hung.  I applied this to master.  Let me know if I
> should backport it.

Hi Ben,

Please help to backport it to branch-2.10.

Thanks,

-Yi-Hung
Ben Pfaff Sept. 7, 2018, 12:06 a.m. UTC | #4
On Thu, Sep 06, 2018 at 04:19:51PM -0700, Yi-Hung Wei wrote:
> On Thu, Sep 6, 2018 at 4:07 PM Ben Pfaff <blp@ovn.org> wrote:
> >
> > On Thu, Sep 06, 2018 at 09:56:26AM -0700, Yi-Hung Wei wrote:
> > > On Thu, Sep 6, 2018 at 6:18 AM Tiago Lam <tiago.lam@intel.com> wrote:
> > > >
> > > > Commit 3f1087c added a per zone limit test which relied on the
> > > > CHECK_CT_DPIF_FLUSH_BY_CT_TUPLE m4 macro to skip the test when executing
> > > > in a userspace datapath (since the per zone limit feature is not yet
> > > > implemented in userspace). That macro, however, has been removed in
> > > > commit 271e48a ("conntrack: Support conntrack flush by ct 5-tuple")
> > > > which was causing the test to fail when executing in userspace.
> > > >
> > > > Instead, a new m4 macro, CHECK_CT_DPIF_PER_ZONE_LIMIT, is introduced to
> > > > make the same differentiation, until userspace doesn't support the per
> > > > zone limit.
> > > >
> > > > CC: Yi-Hung Wei <yihung.wei@gmail.com>
> > > > Fixes: 3f1087c ("system-traffic: Add conntrack per zone limit test case")
> > > > Signed-off-by: Tiago Lam <tiago.lam@intel.com>
> > > > ---
> > > Thanks Tiago for the fix. I will work on the userspace zone limitation later on.
> > >
> > > Acked-by: Yi-Hung Wei <yihung.wei@gmail.com>
> >
> > Thanks Tiago and Yi-Hung.  I applied this to master.  Let me know if I
> > should backport it.
> 
> Hi Ben,
> 
> Please help to backport it to branch-2.10.

Done.
diff mbox series

Patch

diff --git a/tests/system-kmod-macros.at b/tests/system-kmod-macros.at
index 770703b..3296d64 100644
--- a/tests/system-kmod-macros.at
+++ b/tests/system-kmod-macros.at
@@ -114,6 +114,13 @@  m4_define([CHECK_CONNTRACK_FRAG_IPV6_MULT_EXTEN],
 #
 m4_define([CHECK_CONNTRACK_NAT])
 
+# CHECK_CT_DPIF_PER_ZONE_LIMIT()
+#
+# Perform requirements checks for running ovs-dpctl ct-[set|get|del]-limits per
+# zone. The kernel datapath does support this feature. Will remove this check
+# after both kernel and userspace datapath support it.
+m4_define([CHECK_CT_DPIF_PER_ZONE_LIMIT])
+
 # CHECK_CT_DPIF_SET_GET_MAXCONNS()
 #
 # Perform requirements checks for running ovs-dpctl ct-set-maxconns or
diff --git a/tests/system-traffic.at b/tests/system-traffic.at
index 2a33e9f..19cf89a 100644
--- a/tests/system-traffic.at
+++ b/tests/system-traffic.at
@@ -3189,7 +3189,7 @@  AT_CLEANUP
 
 AT_SETUP([conntrack - limit by zone])
 CHECK_CONNTRACK()
-CHECK_CT_DPIF_FLUSH_BY_CT_TUPLE()
+CHECK_CT_DPIF_PER_ZONE_LIMIT()
 OVS_TRAFFIC_VSWITCHD_START()
 
 ADD_NAMESPACES(at_ns0, at_ns1)
diff --git a/tests/system-userspace-macros.at b/tests/system-userspace-macros.at
index 968a95e..27bde8b 100644
--- a/tests/system-userspace-macros.at
+++ b/tests/system-userspace-macros.at
@@ -116,6 +116,15 @@  m4_define([CHECK_CONNTRACK_FRAG_IPV6_MULT_EXTEN],
 #
 m4_define([CHECK_CONNTRACK_NAT])
 
+# CHECK_CT_DPIF_PER_ZONE_LIMIT()
+#
+# Perform requirements checks for running ovs-dpctl ct-[set|get|del]-limits per
+# zone. The userspace datapath does not support this feature yet.
+m4_define([CHECK_CT_DPIF_PER_ZONE_LIMIT],
+[
+    AT_SKIP_IF([:])
+])
+
 # CHECK_CT_DPIF_SET_GET_MAXCONNS()
 #
 # Perform requirements checks for running ovs-dpctl ct-set-maxconns or