On Fri, Oct 14, 2022 at 10:38 PM Olivier Matz <olivier.m...@6wind.com> wrote:
>
> The issue is seen by unit tests:
>
> > root@dpdk-VF-dut247:~/dpdk# MALLOC_PERTURB_=204 \
> >   DPDK_TEST=eventdev_selftest_sw \
> >   /root/dpdk/x86_64-native-linuxapp-gcc/app/test/dpdk-test -c 0xff
> > (...)
> > *** Running XStats ID Reset test...
> > 12: 1761: qid_0_port_2_pinned_flows value , expected 1 got 7
> > 1778: qid_0_port_2_pinned_flows value incorrect, expected 1 got 7
> > ERROR - XStats ID Reset test FAILED.
> > SW Eventdev Selftest Failed.
> > Test Failed
>
> The flow id is not set in the event, which results in an undefined
> flow, whose value depends on what was previously in stack. Having
> different flows for the packets makes the test to fail, since only one
> flow is expected.
>
> This only happens in -O3, where the same stack area is shared by the
> event object and the address of the mbuf allocated in rte_gen_arp().

Good catch.
That's scary...


>
> Fix this by properly initializing the flow id.
>
> Bugzilla ID: 1101
> Fixes: e21df4b062b5 ("test/eventdev: add SW xstats tests")
> Cc: sta...@dpdk.org
>
> Signed-off-by: Olivier Matz <olivier.m...@6wind.com>

Reviewed-by: David Marchand <david.march...@redhat.com>


-- 
David Marchand

Reply via email to