The linuxkpi assumes that PCI devices are already fully configured. However, sometimes video cards are not configured by firmware and need to be initialized instead by FreeBSD.
Linux KPI uses the PCI device resource lists directly, which can fail when a device is not initialized.
According to jhb@, this should be done instead by using pci_find_bar(), and other PCI API functions, in linux_pci_get_bar() instead of trolling through the resource list directly, so that the BARs get properly initialized.
Happy to help where I can on my hardware, but hselasky knows the code best.
Is this relevant for i386 and amd64 or other platforms only?
It might only occur on non-x86 platforms. I know it occurs on powerpc64 with uboot. It might occur on an ARM platform with a PCIe graphics card (highly unlikely that would ever happen). But, the direct use of the RLEs is incorrect, and the public API should be used instead anyway. So much of the work can be done and tested on x86.