All of lore.kernel.org
 help / color / mirror / Atom feed
From: bugzilla@dpdk.org
To: dev@dpdk.org
Subject: [DPDK/vhost/virtio Bug 1866] [dpdk-23.11.6rc1][Cryptodev][LTS test] virtio_perf_cryptodev_func/testvirtio_aes_cbc_sha1_hmac: Failed to use virtio device - Segmentation fault
Date: Fri, 09 Jan 2026 07:05:10 +0000	[thread overview]
Message-ID: <bug-1866-3@http.bugs.dpdk.org/> (raw)

http://bugs.dpdk.org/show_bug.cgi?id=1866

            Bug ID: 1866
           Summary: [dpdk-23.11.6rc1][Cryptodev][LTS test]
                    virtio_perf_cryptodev_func/testvirtio_aes_cbc_sha1_hma
                    c: Failed to use virtio device - Segmentation fault
           Product: DPDK
           Version: 23.11
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: normal
          Priority: Normal
         Component: vhost/virtio
          Assignee: dev@dpdk.org
          Reporter: yux.jiang@intel.com
  Target Milestone: ---

[DPDK Version]
commit 63864b90e2bf91b38d9f4accb588c52ed90cac4e (HEAD -> v23.11.6-rc1, tag:
v23.11.6-rc1, origin/23.11, 23.11)
Author: Shani Peretz <shperetz@nvidia.com>
Date:   Tue Jan 6 15:04:17 2026 +0200

    version: 23.11.6-rc1

    Signed-off-by: Shani Peretz <shperetz@nvidia.com>


[Reproduce]
rm -rf x86_64-native-linuxapp-gcc
CC=gcc meson -Dlibdir=lib --default-library=static x86_64-native-linuxapp-gcc
ninja -C x86_64-native-linuxapp-gcc
meson configure -Dexamples=vhost_crypto x86_64-native-linuxapp-gcc
ninja -C x86_64-native-linuxapp-gcc

SW Device:
rm -r /tmp/*
x86_64-native-linuxapp-gcc/examples/dpdk-vhost_crypto -l 1,2,3 -a 0000:00:00.0
--vdev crypto_aesni_mb_pmd_1 --socket-mem 2048,0 -n 4 -- --config
"(2,0,0),(3,0,0)" --socket-file 2,/tmp/vm0_crypto0.sock
--socket-file=3,/tmp/vm0_crypto1.sock

Create a NIC VF:
echo 1 > /sys/bus/pci/devices/0000\:3b\:00.0/sriov_numvfs
usertools/dpdk-devbind.py --bind=vfio-pci 0000:3b:02.0

lsof -n -i:6600
taskset -c 11,12,13,14,15,16,17,18 /root/qemu-2.12/bin/qemu-system-x86_64 
-name vm0 -enable-kvm -pidfile /tmp/.vm0.pid \
-daemonize -monitor unix:/tmp/vm0_monitor.sock,server,nowait -device
e1000,netdev=nttsip1  \
-netdev user,id=nttsip1,hostfwd=tcp:10.239.252.147:6600-:22 -device
vfio-pci,host=0000:3b:02.0,id=pt_0 \
-cpu host -smp 8 -m 4096 -object
memory-backend-file,id=mem,size=4096M,mem-path=/dev/hugepages,share=on \
-numa node,memdev=mem -mem-prealloc -vnc :1 \
-chardev socket,path=/tmp/vm0_qga0.sock,server,nowait,id=vm0_qga0 -device
virtio-serial -device
virtserialport,chardev=vm0_qga0,name=org.qemu.guest_agent.0 \
-chardev socket,path=/tmp/vm0_crypto0.sock,id=vm0_crypto0 -object
cryptodev-vhost-user,id=cryptodev0,chardev=vm0_crypto0 -device
virtio-crypto-pci,id=crypto0,cryptodev=cryptodev0 \
-chardev socket,path=/tmp/vm0_crypto1.sock,id=vm0_crypto1 -object
cryptodev-vhost-user,id=cryptodev1,chardev=vm0_crypto1 -device
virtio-crypto-pci,id=crypto1,cryptodev=cryptodev1 \
-drive file=/root/VMs/virtio_crypto_vm1.img

In VM:
rm -rf x86_64-native-linuxapp-gcc
CC=gcc meson  -Dlibdir=lib --default-library=static x86_64-native-linuxapp-gcc
ninja -C x86_64-native-linuxapp-gcc -j8

awk '/Hugepagesize/ {print $2}' /proc/meminfo     
echo 0 > /sys/kernel/mm/hugepages/hugepages-2048kB/nr_hugepages   
echo 1024 >
/sys/devices/system/node/node0/hugepages/hugepages-2048kB/nr_hugepages

In VM:
modprobe uio_pci_generic        
lspci -d:1054|awk '{{print $1}}'      
echo 0000:00:07.0 > /sys/bus/pci/devices/0000\:00\:07.0/driver/unbind      
echo 0000:00:06.0 > /sys/bus/pci/devices/0000\:00\:06.0/driver/unbind      
echo "1af4 1054" > /sys/bus/pci/drivers/uio_pci_generic/new_id  

TestVirtioPerfCryptodevFunc: Test Case test_virtio_aes_cbc_sha1_hmac Begin
virtdut.10.239.252.147:6600: 
x86_64-native-linuxapp-gcc/app/dpdk-test-crypto-perf  -l 0,1 -a 00:06.0
--socket-mem 512,0 -n 4  -- --ptest throughput --silent  --total-ops 100000
--burst-sz 32 --buffer-sz 64,128,256,512,1024,2048 --devtype crypto_virtio
--optype cipher-then-auth --cipher-algo aes-cbc --cipher-op encrypt
--cipher-key-sz 16 --cipher-iv-sz 16 --auth-algo sha1-hmac --auth-op generate
--auth-key-sz 64 --digest-sz 12

[Actual log]
vm1:~/dpdk# x86_64-native-linuxapp-gcc/app/dpdk-test-crypto-perf  -l 0,1 -a
00:06.0 --socket-mem 512,0 -n 4  -- --ptest throughput --silent  --total-ops
100000 --burst-sz 32 --buffer-sz 64,128,256,512,1024,2048 --devtype
crypto_virtio --optype cipher-then-auth --cipher-algo aes-cbc --cipher-op
encrypt --cipher-key-sz 16 --cipher-iv-sz 16 --auth-algo sha1-hmac --auth-op
generate --auth-key-sz 64 --digest-sz 12
EAL: Detected CPU lcores: 8
EAL: Detected NUMA nodes: 1
EAL: Detected static linkage of DPDK
EAL: Multi-process socket /var/run/dpdk/rte/mp_socket
EAL: Selected IOVA mode 'PA'
EAL: VFIO support initialized
EAL: Probe PCI driver: crypto_virtio (1af4:1054) device: 0000:00:06.0 (socket
-1)
CRYPTODEV: Creating cryptodev 0000:00:06.0
CRYPTODEV: Initialisation parameters - name: 0000:00:06.0,socket id: -1, max
queue pairs: 0
EAL: Requested device 0000:00:06.0 cannot be used
EAL: Bus (pci) probe failed.
Segmentation fault (core dumped)


[Bad commit]
commit 9c9ce1e0cef63b173df003aa9d5f0d975ed85cf2 (HEAD -> 9c9ce1e0ce)
Author: Rajesh Mudimadugula <rmudimadugul@marvell.com>
Date:   Wed May 28 10:53:47 2025 +0000

    crypto/virtio: fix driver ID

    [ upstream commit 9843181aa5e764fd6876f50e8a795353e9261cb1 ]

    This patch corrects driver id for virtio and virtio_user
    pmds.

    Fixes: 25500d4b8076 ("crypto/virtio: support device init")

    Signed-off-by: Rajesh Mudimadugula <rmudimadugul@marvell.com>
    Acked-by: Akhil Goyal <gakhil@marvell.com>

Compare that dpdk stable branch has some gaps with dpdk main branch, may need
rebase.

-- 
You are receiving this mail because:
You are the assignee for the bug.

                 reply	other threads:[~2026-01-09  7:05 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=bug-1866-3@http.bugs.dpdk.org/ \
    --to=bugzilla@dpdk.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.