On 1/3/22 15:15, David Marchand wrote: > The MFEX code and tests do not depend on DPDK anymore. > We can move the unit tests to dpif-netdev. > > Signed-off-by: David Marchand <[email protected]> > Reviewed-by: Maxime Coquelin <[email protected]> > Acked-by: Eelco Chaudron <[email protected]> > Acked-by: Kumar Amber <[email protected]> > --- > Note: this patch depends on series > https://patchwork.ozlabs.org/project/openvswitch/list/?series=274452 > > Changes since v3: > - removed documentation update, > > --- > tests/dpif-netdev.at | 167 +++++++++++++++++++++++++++++++++++++ > tests/system-dpdk.at | 194 ------------------------------------------- > 2 files changed, 167 insertions(+), 194 deletions(-) > > diff --git a/tests/dpif-netdev.at b/tests/dpif-netdev.at > index 53eee185ad..fbb8fe9a71 100644 > --- a/tests/dpif-netdev.at > +++ b/tests/dpif-netdev.at > @@ -635,3 +635,170 @@ OVS_WAIT_UNTIL([grep "flow: in_port is not an exact > match" ovs-vswitchd.log]) > OVS_VSWITCHD_STOP(["/flow: in_port is not an exact match/d > /failed to put/d"]) > AT_CLEANUP > + > +AT_SETUP([dpif-netdev - MFEX Autovalidator]) > +AT_SKIP_IF([! $PYTHON3 -c "import scapy"], [], []) > +OVS_VSWITCHD_START( > + [add-port br0 p1 \ > + -- set interface p1 type=dummy-pmd]) > + > +AT_SKIP_IF([! ovs-appctl dpif-netdev/miniflow-parser-get | sed 1,4d | grep > "True"], [], [dnl > +]) > + > +on_exit "pkill -f -x -9 '$PYTHON3 $srcdir/genpkts.py -1'" > +($PYTHON3 $srcdir/genpkts.py -1 | while read pkt; do > + ovs-appctl netdev-dummy/receive p1 "$pkt" || break > + done) & > + > +AT_CHECK([ovs-appctl dpif-netdev/miniflow-parser-set autovalidator], [0], > [dnl > +Miniflow extract implementation set to autovalidator. > +]) > + > +OVS_WAIT_UNTIL([test `ovs-vsctl get interface p1 statistics:rx_packets` -ge > 1000]) > +pkill -f -x -9 '$PYTHON3 $srcdir/genpkts.py -1' > + > +OVS_VSWITCHD_STOP > +AT_CLEANUP > + > +AT_SETUP([dpif-netdev - MFEX Autovalidator Fuzzy]) > +AT_SKIP_IF([! $PYTHON3 -c "import scapy"], [], []) > +OVS_VSWITCHD_START( > + [add-port br0 p1 \ > + -- set interface p1 type=dummy-pmd]) > + > +AT_SKIP_IF([! ovs-appctl dpif-netdev/miniflow-parser-get | sed 1,4d | grep > "True"], [], [dnl > +]) > + > +on_exit "pkill -f -x -9 '$PYTHON3 $srcdir/genpkts.py -1 fuzz'" > +($PYTHON3 $srcdir/genpkts.py -1 fuzz | while read pkt; do > + ovs-appctl netdev-dummy/receive p1 "$pkt" || break > + done) & > + > +AT_CHECK([ovs-appctl dpif-netdev/miniflow-parser-set autovalidator], [0], > [dnl > +Miniflow extract implementation set to autovalidator. > +]) > + > +OVS_WAIT_UNTIL([test `ovs-vsctl get interface p1 statistics:rx_packets` -ge > 1000]) > +pkill -f -x -9 '$PYTHON3 $srcdir/genpkts.py -1 fuzz' > + > +OVS_VSWITCHD_STOP > +AT_CLEANUP > + > +AT_SETUP([dpif-netdev - MFEX Configuration]) > +AT_SKIP_IF([! $PYTHON3 -c "import scapy"], [], []) > +OVS_VSWITCHD_START( > + [add-port br0 p1 \ > + -- set Open_vSwitch . other_config:pmd-cpu-mask=0xC \ > + -- set interface p1 type=dummy-pmd])
This test and others in here need a dummy-numa configured. 2 reasons for that: 1. We're asking for 4 CPU cores here (0xC), so the test will not work as expected on a smaller system (e.g. GHA). 2. Without dummy-numa real CPU affinity will be applied. In that case during the parallel test execution threads from different tests will be scheduled on same cores. Dummy-numa fakes the CPU affinity allowing the kernel to re-schedule pmd threads to different cores better utilising system resources. Best regards, Ilya Maximets. _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
