[Bug 250802] bhyve exited with status 134 when GPU PCI passthrough

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Sun Nov 8 09:26:25 UTC 2020


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

--- Comment #31 from mr.xanto at gmail.com ---
(In reply to Konstantin Belousov from comment #30)

# /usr/local/bin/gdb /usr/sbin/bhyve
GNU gdb (GDB) 9.2 [GDB v9.2 for FreeBSD]

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/sbin/bhyve...
(gdb) set args -c 1 -m 3G -Hwl
bootrom,/usr/local/share/uefi-firmware/BHYVE_UEFI.fd -U
00dad61d-0d2e-11eb-936d-70f3951447ea -S -s 0,hostbridge -s 31,lpc -s
4:0,ahci,hd:/mnt/Data/vm/win10/disk0.img -s
5:0,virtio-net,tap0,mac=58:9c:fc:01:00:a8 -s 6:0,passthru,1/0/0 -s
6:1,passthru,1/0/1 win10
(gdb) run
Assertion failed: (pi->pi_bar[baridx].type == PCIBAR_IO), function
passthru_write, file /usr/src/usr.sbin/bhyve/pci_passthru.c, line 916.

Thread 11 "vcpu 0" received signal SIGABRT, Aborted.
[Switching to LWP 101424 of process 52943]
0x000000080080aafa in thr_kill () from /lib/libc.so.7
(gdb) backtrace
#0  0x000000080080aafa in thr_kill () from /lib/libc.so.7
#1  0x0000000800808f54 in raise () from /lib/libc.so.7
#2  0x000000080077f259 in abort () from /lib/libc.so.7
#3  0x00000008007f9161 in __assert () from /lib/libc.so.7
#4  0x000000000023d9e4 in passthru_write (ctx=0x800299080, vcpu=0,
pi=0x800ad4780, baridx=1, offset=242044928, size=4, value=0)
    at /usr/src/usr.sbin/bhyve/pci_passthru.c:916
#5  0x000000000023685f in pci_emul_mem_handler (ctx=0x800299080, vcpu=6,
dir=<optimized out>, addr=<optimized out>, size=<optimized out>,
val=0x7fffdedf4d60,
    arg1=0x800ad4780, arg2=1) at /usr/src/usr.sbin/bhyve/pci_emul.c:411
#6  0x0000000000228c15 in mem_write (ctx=0x18c30, vcpu=6, gpa=34368170778,
wval=0, size=0, arg=0x0) at /usr/src/usr.sbin/bhyve/mem.c:162
#7  0x000000000024ebb6 in emulate_mov (vm=<optimized out>, vcpuid=<optimized
out>, gpa=<optimized out>, vie=<optimized out>, memread=<optimized out>,
    memwrite=0x228be0 <mem_write>, arg=0x800b76100) at
/usr/src/sys/amd64/vmm/vmm_instruction_emul.c:600
#8  vmm_emulate_instruction (vm=<optimized out>, vcpuid=<optimized out>,
gpa=<optimized out>, vie=<optimized out>, paging=<optimized out>,
memread=<optimized out>,
    memwrite=0x228be0 <mem_write>, memarg=0x800b76100) at
/usr/src/sys/amd64/vmm/vmm_instruction_emul.c:1697
#9  0x000000000022859f in emulate_mem_cb (ctx=0x18c30, vcpu=6, paddr=0, mr=0x0,
arg=<optimized out>) at /usr/src/usr.sbin/bhyve/mem.c:238
#10 0x00000000002284c4 in access_memory (ctx=0x800299080, vcpu=0,
paddr=3731705856, cb=0x228580 <emulate_mem_cb>, arg=0x7fffdedf4ee8)
    at /usr/src/usr.sbin/bhyve/mem.c:215
#11 0x00000000002283e9 in emulate_mem (ctx=0x18c30, vcpu=6, paddr=0,
vie=<optimized out>, paging=<optimized out>) at
/usr/src/usr.sbin/bhyve/mem.c:251
#12 0x000000000021e845 in vmexit_inst_emul (ctx=0x18c30, vmexit=0x256140
<vmexit>, pvcpu=<optimized out>) at /usr/src/usr.sbin/bhyve/bhyverun.c:716
#13 0x000000000021e29c in vm_loop (ctx=0x800299080, vcpu=0, startrip=65520) at
/usr/src/usr.sbin/bhyve/bhyverun.c:853
#14 0x000000000021d5a3 in fbsdrun_start_thread (param=0x2569c0 <mt_vmm_info>)
at /usr/src/usr.sbin/bhyve/bhyverun.c:427
#15 0x0000000800635fac in ?? () from /lib/libthr.so.3
#16 0x0000000000000000 in ?? ()
Backtrace stopped: Cannot access memory at address 0x7fffdedf5000
(gdb) f 4
#4  0x000000000023d9e4 in passthru_write (ctx=0x800299080, vcpu=0,
pi=0x800ad4780, baridx=1, offset=242044928, size=4, value=0)
    at /usr/src/usr.sbin/bhyve/pci_passthru.c:916
916                     assert(pi->pi_bar[baridx].type == PCIBAR_IO);
(gdb) p/x pi->pi_bar
$1 = {{type = 0x2, size = 0x1000000, addr = 0xc1000000}, {type = 0x3, size =
0x10000000, addr = 0xd0000000}, {type = 0x4, size = 0x0, addr = 0x0}, {type =
0x3,
    size = 0x2000000, addr = 0xc2000000}, {type = 0x4, size = 0x0, addr = 0x0},
{type = 0x1, size = 0x80, addr = 0x2080}}
(gdb)

bhyvectl --get-all: https://pastebin.com/u1exMRin

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


More information about the freebsd-virtualization mailing list