[Bug 205549] bhyve pci passthru stops working after guest is restarted
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Thu Jun 13 18:36:20 UTC 2019
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=205549
--- Comment #6 from arkadyi <ark at dudevich.dn.ua> ---
Hmm....I don't see in the file usr.sbin/bhyve/pci_passthru.c (origin) bellow
strings
642 pci_set_cfgdata16(pi, PCIR_COMMAND, read_config(&sc->psc_sel,
643 PCIR_COMMAND, 2));
# patch < D20623.diff
Hmm... Looks like a unified diff to me...
The text leading up to this was:
--------------------------
|Index: usr.sbin/bhyve/pci_passthru.c
|===================================================================
|--- usr.sbin/bhyve/pci_passthru.c
|+++ usr.sbin/bhyve/pci_passthru.c
--------------------------
Patching file pci_passthru.c using Plan A...
Hunk #1 succeeded at 615 (offset -3 lines).
Hunk #2 succeeded at 625 (offset -3 lines).
Hunk #3 failed at 648.
1 out of 3 hunks failed--saving rejects to pci_passthru.c.rej
done
cat /usr/src/usr.sbin/bhyve/pci_passthru.c.rej
@@ -636,8 +648,13 @@
goto done;
}
- pci_set_cfgdata16(pi, PCIR_COMMAND, read_config(&sc->psc_sel,
- PCIR_COMMAND, 2));
+ /*
+ * Fetch the updated virtual command register and write it to
+ * the device if needed.
+ */
+ cmd = pci_get_cfgdata16(pi, PCIR_COMMAND);
+ if (cmd != orig_cmd)
+ write_config(&sc->psc_sel, PCIR_COMMAND, 2, cmd);
error = 0; /* success */
done:
uname -srv
FreeBSD 12.0-RELEASE-p5 FreeBSD 12.0-RELEASE-p5 r349013
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the freebsd-virtualization
mailing list