]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
bhyve: avoid allocating BARs above the end of supported physical addresses.
authorkib <kib@FreeBSD.org>
Thu, 12 Nov 2020 00:46:53 +0000 (00:46 +0000)
committerkib <kib@FreeBSD.org>
Thu, 12 Nov 2020 00:46:53 +0000 (00:46 +0000)
commit14685f0b9303b981f436f5b357e27e1cf333c974
tree11c593c348e8991ba6db4e4142f4254c40d5cdce
parentc60bae27436d552a3f039ed4c7e5787098367d7f
bhyve: avoid allocating BARs above the end of supported physical addresses.

Read CPUID leaf 0x8000008 to determine max supported phys address and
create BAR region right below it, reserving 1/4 of the supported guest
physical address space to the 64bit BARs mappings.

PR:    250802 (although the issue from PR is not fixed by the change)
Noted and reviewed by: grehan
Sponsored by: The FreeBSD Foundation
MFC after: 2 weeks
Differential revision: https://reviews.freebsd.org/D27095
usr.sbin/bhyve/pci_emul.c