https://bugs.dpdk.org/show_bug.cgi?id=1401 Bug ID: 1401 Summary: [dpdk-24.03][asan] cbdma: ERROR: AddressSanitizer: SEGV on unknown address in rte_rwlock_write_lock when launch dpdk-dma Product: DPDK Version: unspecified Hardware: All OS: All Status: UNCONFIRMED Severity: normal Priority: Normal Component: examples Assignee: dev@dpdk.org Reporter: yux.jiang@intel.com Target Milestone: --- [Environment] DPDK version: a86f381b82 (HEAD -> main, tag: v24.03-rc2, origin/main, origin/HEAD) version: 24.03-rc2 Other software versions: name/version for QEMU, OVS, etc. Repeat as required. OS: Ubuntu 22.04.3 LTS/5.15.0-92-generic Compiler: gcc version 11.4.0 Hardware platform: Intel(R) Xeon(R) Platinum 8380 CPU @ 2.30GHz [Test Setup] Steps to reproduce List the steps to reproduce the issue. 1, Build app and set randomize_va_space=0 rm -fr x86_64-native-linuxapp-gcc/ CC=gcc meson -Denable_kmods=True -Dlibdir=lib -Dbuildtype=debug -Db_lundef=false -Db_sanitize=address --default-library=static x86_64-native-linuxapp-gcc meson configure -Dexamples=dma x86_64-native-linuxapp-gcc ninja -C x86_64-native-linuxapp-gcc echo 0 > /proc/sys/kernel/randomize_va_space 2, Bind dma to vfio-pci ./usertools/dpdk-devbind.py --force --bind=vfio-pci 0000:00:01.0 0000:00:01.1 0000:00:01.2 0000:00:01.3 3, Launch primary app x86_64-native-linuxapp-gcc/app/dpdk-testpmd -l 5-6 -n 8 -a 0000:00:01.0 -a 0000:00:01.1 -a 0000:00:01.2 -a 0000:00:01.3 --file-prefix=dpdk_2693680_20240314155440 --vdev net_null_0 --proc-type=primary -- -i testpmd> port stop all 4, Launch secondary app: dpdk-dma x86_64-native-linuxapp-gcc/examples/dpdk-dma -l 5-7 -n 8 -a 0000:00:01.0 -a 0000:00:01.1 -a 0000:00:01.2 -a 0000:00:01.3 --file-prefix=dpdk_2693680_20240314155440 --proc-type=secondary --vdev net_null_0 -- -p 0x1 -q 4 --no-mac-updating -c hw Show the output from the previous commands: EAL: Detected CPU lcores: 80 EAL: Detected NUMA nodes: 2 EAL: Detected static linkage of DPDK EAL: Cannot mmap memory for rte_config at [0x7ffff4007000], got [0x7ffff3dc9000] - please use '--base-virtaddr' option EAL: FATAL: Cannot init config EAL: Cannot init config EAL: Error - exiting with code: 1 Cause: Invalid EAL arguments AddressSanitizer:DEADLYSIGNAL ================================================================= ==2802374==ERROR: AddressSanitizer: SEGV on unknown address 0x7ffff3dc9024 (pc 0x555556ba5798 bp 0x7fffffffde90 sp 0x7fffffffde00 T0) ==2802374==The signal is caused by a READ memory access. #0 0x555556ba5798 in rte_rwlock_write_lock ../lib/eal/include/generic/rte_rwlock.h:209 #1 0x555556ba9a82 in rte_eal_memory_detach ../lib/eal/common/eal_common_memory.c:1029 #2 0x555556c04fb5 in rte_eal_cleanup ../lib/eal/linux/eal.c:1379 #3 0x555556b8f610 in rte_exit ../lib/eal/common/eal_common_debug.c:46 #4 0x555555ec144b in main ../examples/dma/dmafwd.c:1021 #5 0x7ffff7225d8f in __libc_start_call_main ../sysdeps/nptl/libc_start_call_main.h:58 #6 0x7ffff7225e3f in __libc_start_main_impl ../csu/libc-start.c:392 #7 0x555555e89074 in _start (/root/dpdk/x86_64-native-linuxapp-gcc/examples/dpdk-dma+0x935074) AddressSanitizer can not provide additional info. SUMMARY: AddressSanitizer: SEGV ../lib/eal/include/generic/rte_rwlock.h:209 in rte_rwlock_write_lock ==2802374==ABORTING [Expected Result] Launch app successfully and no Asan error [Regression] Is this issue a regression: (Y/N) Y Version the regression was introduced: (Need https://bugs.dpdk.org/show_bug.cgi?id=1387's patch) commit 52c386779fcd9f31708f1491961637c31f6bcb61 (HEAD -> 52c386779f) Author: Damodharam Ammepalli Date: Wed Sep 20 13:27:17 2023 -0700 net/bnxt: support 400G speed for P7 devices P7 devices report speeds over speeds2 hsi fields. Adding required support to capture the capability from phy_qcap and save the speeds2 fields into driver priv structure. In fixed mode update the link_speed from force_link_speeds2 field. Updates to logging to provide more info regarding numbers of lanes and the link signal mode. Some code refactoring done for PHY auto detect and displaying XCVR information. Signed-off-by: Damodharam Ammepalli Reviewed-by: Ajit Khaparde if don't set echo 0 > /proc/sys/kernel/randomize_va_space, this error disappears -- You are receiving this mail because: You are the assignee for the bug.