freebsd-skq/sys/amd64/vmm/io
D Scott Phillips f8a6ec2d57 bhyve: support relocating fbuf and passthru data BARs
We want to allow the UEFI firmware to enumerate and assign
addresses to PCI devices so we can boot from NVMe[1]. Address
assignment of PCI BARs is properly handled by the PCI emulation
code in general, but a few specific cases need additional support.
fbuf and passthru map additional objects into the guest physical
address space and so need to handle address updates. Here we add a
callback to emulated PCI devices to inform them of a BAR
configuration change. fbuf and passthru then watch for these BAR
changes and relocate the frame buffer memory segment and passthru
device mmio area respectively.

We also add new VM_MUNMAP_MEMSEG and VM_UNMAP_PPTDEV_MMIO ioctls
to vmm(4) to facilitate the unmapping needed for addres updates.

[1]: https://github.com/freebsd/uefi-edk2/pull/9/

Originally by:	scottph
MFC After:	1 week
Sponsored by:	Intel Corporation
Reviewed by:	grehan
Approved by:	philip (mentor)
Differential Revision:	https://reviews.freebsd.org/D24066
2021-03-19 11:04:36 +08:00
..
iommu.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (4 of many) 2020-02-15 18:57:49 +00:00
iommu.h
ppt.c bhyve: support relocating fbuf and passthru data BARs 2021-03-19 11:04:36 +08:00
ppt.h bhyve: support relocating fbuf and passthru data BARs 2021-03-19 11:04:36 +08:00
vatpic.c amd64: clean up empty lines in .c and .h files 2020-09-01 21:16:54 +00:00
vatpic.h Initial support for bhyve save and restore. 2020-05-05 00:02:04 +00:00
vatpit.c amd64: clean up empty lines in .c and .h files 2020-09-01 21:16:54 +00:00
vatpit.h Initial support for bhyve save and restore. 2020-05-05 00:02:04 +00:00
vhpet.c Initial support for bhyve save and restore. 2020-05-05 00:02:04 +00:00
vhpet.h Initial support for bhyve save and restore. 2020-05-05 00:02:04 +00:00
vioapic.c bhyve/ioapic: improve the tracking of IRR bit 2021-02-02 09:47:00 +01:00
vioapic.h Initial support for bhyve save and restore. 2020-05-05 00:02:04 +00:00
vlapic_priv.h Simplify bhyve vlapic ESR logic. 2019-08-29 18:23:38 +00:00
vlapic.c amd64: clean up empty lines in .c and .h files 2020-09-01 21:16:54 +00:00
vlapic.h Initial support for bhyve save and restore. 2020-05-05 00:02:04 +00:00
vpmtmr.c Initial support for bhyve save and restore. 2020-05-05 00:02:04 +00:00
vpmtmr.h Initial support for bhyve save and restore. 2020-05-05 00:02:04 +00:00
vrtc.c Initial support for bhyve save and restore. 2020-05-05 00:02:04 +00:00
vrtc.h Initial support for bhyve save and restore. 2020-05-05 00:02:04 +00:00