DPDK patches and discussions
 help / color / mirror / Atom feed
From: Stephen Hemminger <stephen@networkplumber.org>
To: dev@dpdk.org
Subject: [dpdk-dev] PCI valgrind detects unintialized access
Date: Wed, 18 Aug 2021 18:14:41 -0700	[thread overview]
Message-ID: <20210818181441.4aff89a8@hermes.local> (raw)

As a sanity test, running lastest DPDK testpmd with valgrind (on x86).

One concern is that the PCI code appears to be looking at flags in
the PCI device (not from the driver) which are not initialized.

The probe logic is a confusing, any recommendation on best fix?

==1695615== Command: build/app/dpdk-testpmd --log-level=debug --log-level=eal:debug -c 1
==1695615== 
EAL: Detected 16 lcore(s)
EAL: Detected 1 NUMA nodes
EAL: Detected static linkage of DPDK
EAL: Multi-process socket /var/run/dpdk/rte/mp_socket
==1695615== Conditional jump or move depends on uninitialised value(s)
==1695615==    at 0xCF7929: rte_pci_get_iommu_class (pci_common.c:666)
==1695615==    by 0xCAC89C: rte_bus_get_iommu_class (eal_common_bus.c:214)
==1695615==    by 0xCC8878: rte_eal_init (eal.c:1084)
==1695615==    by 0x4ED5E4: main (testpmd.c:3809)
==1695615== 
==1695615== Conditional jump or move depends on uninitialised value(s)
==1695615==    at 0xCF79BB: rte_pci_get_iommu_class (pci_common.c:666)
==1695615==    by 0xCAC89C: rte_bus_get_iommu_class (eal_common_bus.c:214)
==1695615==    by 0xCC8878: rte_eal_init (eal.c:1084)
==1695615==    by 0x4ED5E4: main (testpmd.c:3809)
==1695615== 
EAL: Selected IOVA mode 'PA'
EAL: No available 1048576 kB hugepages reported
==1695615== Warning: set address range perms: large range [0x100200000, 0x500400000) (noaccess)
==1695615== Warning: set address range perms: large range [0x500400000, 0x900600000) (noaccess)
==1695615== Warning: set address range perms: large range [0x900600000, 0xd00800000) (noaccess)
==1695615== Warning: set address range perms: large range [0x1010859000, 0x1410a59000) (noaccess)
==1695615== Warning: set address range perms: large range [0x1010859000, 0x1410a59000) (noaccess)
==1695615== Warning: set address range perms: large range [0x1010859000, 0x1410a59000) (noaccess)
==1695615== Warning: set address range perms: large range [0x1010859000, 0x1410a59000) (noaccess)
==1695615== Warning: set address range perms: large range [0x1010859000, 0x1410a59000) (noaccess)
==1695615== Warning: set address range perms: large range [0x1010859000, 0x1410a59000) (noaccess)
==1695615== Warning: set address range perms: large range [0x1010859000, 0x1410a59000) (noaccess)
==1695615== Warning: set address range perms: large range [0x1010859000, 0x1410a59000) (noaccess)
==1695615== Warning: set address range perms: large range [0x1010859000, 0x1410a59000) (noaccess)
==1695615== Warning: set address range perms: large range [0x1010859000, 0x1410a59000) (noaccess)
==1695615== Warning: set address range perms: large range [0x1010859000, 0x1410a59000) (noaccess)
EAL: WARNING! Base virtual address hint (0xd01061000 != 0x1010a00000) not respected!
EAL:    This may cause issues with mapping memory into secondary processes
==1695615== Conditional jump or move depends on uninitialised value(s)
==1695615==    at 0xCF91C9: pci_device_iova_mode (pci.c:611)
==1695615==    by 0x2F498D: rte_pci_probe_one_driver (pci_common.c:219)
==1695615==    by 0x2F498D: pci_probe_all_drivers (pci_common.c:321)
==1695615==    by 0x2F498D: pci_probe.cold (pci_common.c:348)
==1695615==    by 0xCAC692: rte_bus_probe (eal_common_bus.c:72)
==1695615==    by 0x2EC82F: rte_eal_init.cold (eal.c:1291)
==1695615==    by 0x4ED5E4: main (testpmd.c:3809)
==1695615== 
==1695615== Conditional jump or move depends on uninitialised value(s)
==1695615==    at 0xCF91D1: pci_device_iova_mode (pci.c:611)
==1695615==    by 0x2F498D: rte_pci_probe_one_driver (pci_common.c:219)
==1695615==    by 0x2F498D: pci_probe_all_drivers (pci_common.c:321)
==1695615==    by 0x2F498D: pci_probe.cold (pci_common.c:348)
==1695615==    by 0xCAC692: rte_bus_probe (eal_common_bus.c:72)
==1695615==    by 0x2EC82F: rte_eal_init.cold (eal.c:1291)
==1695615==    by 0x4ED5E4: main (testpmd.c:3809)
==1695615== 
==1695615== Conditional jump or move depends on uninitialised value(s)
==1695615==    at 0xCF873D: rte_pci_map_device (pci.c:66)
==1695615==    by 0x2F49B8: rte_pci_probe_one_driver (pci_common.c:234)
==1695615==    by 0x2F49B8: pci_probe_all_drivers (pci_common.c:321)
==1695615==    by 0x2F49B8: pci_probe.cold (pci_common.c:348)
==1695615==    by 0xCAC692: rte_bus_probe (eal_common_bus.c:72)
==1695615==    by 0x2EC82F: rte_eal_init.cold (eal.c:1291)
==1695615==    by 0x4ED5E4: main (testpmd.c:3809)
==1695615== 

                 reply	other threads:[~2021-08-19  1:14 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210818181441.4aff89a8@hermes.local \
    --to=stephen@networkplumber.org \
    --cc=dev@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).