On 5/12/22 15:56, Stanisław Kardach wrote:
On Thu, May 12, 2022 at 11:46 AM Heinrich Schuchardt
<heinrich.schucha...@canonical.com> wrote:
<snip>
The above failures for performance tests without a bound NIC can be
reproduced on x86_64. So this is not RISC-V specific.

With both ports of an Intel Corporation Ethernet Controller 10-Gigabit
X540-AT2 bound to the sfio-pci driver some fast tests fail on the
Unmatched board:

   16/173 DPDK:fast-tests / eal_flags_n_opt_autotest FAIL 5.54s (exit
status 255 or signal 127 SIGinvalid)
  >>> DPDK_TEST=eal_flags_n_opt_autotest MALLOC_PERTURB_=31
build/app/test/dpdk-test --file-prefix=eal_flags_n_opt_autotest
   18/173 DPDK:fast-tests / eal_flags_no_huge_autotest FAIL 5.31s (exit
status 255 or signal 127 SIGinvalid)
  >>> DPDK_TEST=eal_flags_no_huge_autotest MALLOC_PERTURB_=150
build/app/test/dpdk-test --file-prefix=eal_flags_no_huge_autotest
   21/173 DPDK:fast-tests / eal_flags_vdev_opt_autotest FAIL 5.38s (exit
status 255 or signal 127 SIGinvalid)
  >>> MALLOC_PERTURB_=71 DPDK_TEST=eal_flags_vdev_opt_autotest
build/app/test/dpdk-test --file-prefix=eal_flags_vdev_opt_autotest
   25/173 DPDK:fast-tests / eal_flags_misc_autotest FAIL 5.58s (exit
status 255 or signal 127 SIGinvalid)
  >>> DPDK_TEST=eal_flags_misc_autotest MALLOC_PERTURB_=130
build/app/test/dpdk-test --file-prefix=eal_flags_misc_autotest

The eal* tests succeed on x86_64 with a bound Intel I211 NIC.
The common element of those tests is --no-huge flag. The reason why
they are failing is a combination of --no-huge and a lack of IOMMU
(VT-d on Intel). Lack of IOMMU means that DMA will be done using
physical addresses (RTE_IOVA_PA), however that implicitly requires
hugepages to function. More details are in [1]. That mail also shows
how to replicate the same issue on x86 even without a device bound to
UIO.
The following fails:
   $ ./app/test/dpdk-test --iova-mode=pa --no-huge
But this works:
   sudo ./app/test/dpdk-test --iova-mode=pa
However fixing it is not as straightforward as I thought (some tests
are not run where they should - [3]). As I explain in [2], the PCI bus
probing may force RTE_IOVA_PA on no-IOMMU platforms. That gives the
same effect as passing `--iova-mode=pa`. If no PCI device is bound,
then DPDK will be in RTE_IOVA_DC mode and that works just fine with
--no-huge.

As DPDK CI does not bind any device for fast-tests I've concluded that
it is the way those tests should be run. If not then I'm not sure how
should I handle --iova-mode=pa + --no-huge in general. Any
suggestions?

Thanks for your analysis and explanation. The respective tests should return TEST_SKIPPED if called with an unsupported parameter combination.

According to your analysis this is not a problem specific to the RISC-V series but can be resolved separately.

Maybe you could add a note in doc/guides/rel_notes/known_issues.rst.

Best regards

Heinrich


[1] http://mails.dpdk.org/archives/dev/2021-June/210773.html
[2] http://mails.dpdk.org/archives/dev/2021-June/211146.html
[3] 
https://patches.dpdk.org/project/dpdk/patch/20210604141601.275430-4-...@semihalf.com/


If the eal* tests are run depends on the installed Linux packages. I
have used 'apt build-dep dpdk' on Ubuntu Jammy to install prerequisite
packages before building DPDK.

Best regards

Heinrich

Reply via email to