[Bug 254513] virtio_random: random_harvestq spinning on a CPU with Q35 virtio random device

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Sat May 29 15:25:23 UTC 2021


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=254513

--- Comment #10 from Matthias Andree <mandree at FreeBSD.org> ---
since my virtual server is rented with just one core, it goes down to a crawl.
More information:

# kldload virtio_random ; devinfo -p vtrnd0 -v ; kldunload virtio_random
vtrnd0 pnpinfo vendor=0x00001af4 device=0x1005 subvendor=0x1af4
device_type=0x00000004
 virtio_pci4 pnpinfo vendor=0x1af4 device=0x1005 subvendor=0x1af4
subdevice=0x0004 class=0x00ff00 at slot=7 function=0 dbsf=pci0:0:7:0
handle=\_SB_.PCI0.S38_
 pci0
 pcib0 pnpinfo _HID=PNP0A03 _UID=1 _CID=none at handle=\_SB_.PCI0
 acpi0
 nexus0



# pciconf -l -v
[...]
virtio_pci4 at pci0:0:7:0: class=0x00ff00 rev=0x00 hdr=0x00 vendor=0x1af4
device=0x1005 subvendor=0x1af4 subdevice=0x0004
    vendor     = 'Red Hat, Inc.'
    device     = 'Virtio RNG'
    class      = old



# dmesg

CPU: Intel Xeon E312xx (Sandy Bridge) (2600.04-MHz K8-class CPU)
  Origin="GenuineIntel"  Id=0x206a1  Family=0x6  Model=0x2a  Stepping=1
 
Features=0x783fbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,MMX,FXSR,SSE,SSE2>
 
Features2=0x9fba2203<SSE3,PCLMULQDQ,SSSE3,CX16,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,TSCDLT,AESNI,XSAVE,OSXSAVE,AVX,HV>
  AMD Features=0x28100800<SYSCALL,NX,RDTSCP,LM>
  AMD Features2=0x1<LAHF>
  XSAVE Features=0x1<XSAVEOPT>
...

virtio_pci0: <VirtIO PCI (legacy) Network adapter> port 0xc0a0-0xc0bf mem
0xfebf1000-0xfebf1fff,0xfe000000-0xfe003fff irq 11 at device 3.0 on pci0
vtnet0: <VirtIO Networking Adapter> on virtio_pci0
vtnet0: Ethernet address: 00:1a:4a:d0:17:bf
vtnet0: netmap queues/slots: TX 1/256, RX 1/128
000.000760 [ 450] vtnet_netmap_attach       vtnet attached txq=1, txd=256
rxq=1, rxd=128
virtio_pci1: <VirtIO PCI (legacy) Block adapter> port 0xc000-0xc03f mem
0xfebf2000-0xfebf2fff,0xfe004000-0xfe007fff irq 11 at device 4.0 on pci0
vtblk0: <VirtIO Block Adapter> on virtio_pci1
vtblk0: 20480MB (41943040 512 byte sectors)
virtio_pci2: <VirtIO PCI (legacy) Block adapter> port 0xc040-0xc07f mem
0xfebf3000-0xfebf3fff,0xfe008000-0xfe00bfff irq 10 at device 5.0 on pci0
vtblk1: <VirtIO Block Adapter> on virtio_pci2
vtblk1: 1024MB (2097152 512 byte sectors)
virtio_pci3: <VirtIO PCI (legacy) Balloon adapter> port 0xc0c0-0xc0df mem
0xfe00c000-0xfe00ffff irq 10 at device 6.0 on pci0
vtballoon0: <VirtIO Balloon Adapter> on virtio_pci3
virtio_pci4: <VirtIO PCI (legacy) Entropy adapter> port 0xc0e0-0xc0ff mem
0xfe010000-0xfe013fff irq 11 at device 7.0 on pci0
...
vtrnd0: <VirtIO Entropy Adapter> on virtio_pci4
random: registering fast source VirtIO Entropy Adapter
[... kldunload here ...]
vtrnd0: detached



# kldload virtio_random ; sleep 5 ; procstat -w 1 kstack 7 ; kldunload
virtio_random
  PID    TID COMM                TDNAME              KSTACK                     
    7 100061 rand_harvestq       -                   mi_switch sleepq_timedwait
_sleep random_kthread fork_exit fork_trampoline 
    7 100061 rand_harvestq       -                   mi_switch sleepq_timedwait
_sleep random_kthread fork_exit fork_trampoline 
    7 100061 rand_harvestq       -                   mi_switch sleepq_timedwait
_sleep random_kthread fork_exit fork_trampoline 
    7 100061 rand_harvestq       -                   mi_switch sleepq_timedwait
_sleep random_kthread fork_exit fork_trampoline

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


More information about the freebsd-virtualization mailing list